Get OEIS Sequence Terms
oeis_get_termsList terms a(n) of a sequence with their indices n. Reads the entry's b-file when it has one — often thousands of terms beyond the data line — and otherwise the data line itself. Values are exact decimal strings of any size. A slice returns up to limit terms (at most 1000 per call) and may read the next b-file part to fill it. Pass nextFromIndex to continue.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"aNumber": "<aNumber>"
},
"name": "oeis_get_terms"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Maximum number of terms to return (default 100). One call returns at most 1000, so a larger limit is served as 1000. A slice can end early when fewer terms are available to this call. Pass nextFromIndex to continue. | |
| aNumber | Yes | OEIS A-number, e.g. "A000045"; oeis_identify_sequence and oeis_search_sequences return them. Also accepts "a000045", "A45", "45", and an oeis.org sequence URL; all normalize to the zero-padded form. Legacy M/N book numbers (e.g. "M1459") are not A-numbers: find them with oeis_search_sequences. | |
| fromIndex | No | First index n to return; defaults to the first available index. Pass nextFromIndex from the previous call to continue. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cap | No | The limit that was applied: limit, or 1000 when limit is larger. | |
| url | No | Sequence page on oeis.org; cite it wherever the terms are reused. | |
| error | No | Present when the call failed. Absent on success. | |
| shown | No | Terms in this slice. | |
| terms | No | Terms in index order, from the first index at or after fromIndex (or the first available index). | |
| notice | No | Guidance on continuing the slice, a short or empty slice, skipped b-file lines, the b-file read bounds, or data-line-only terms. | |
| source | No | bfile: read from the entry's b-file of extended terms. data: the entry has no b-file, so these are its data-line terms. | |
| aNumber | No | A-number, e.g. "A000045". | |
| bFileCut | No | True when the b-file may contain terms beyond lastAvailableIndex. Follow nextFromIndex or the notice to check, or consult bFileUrl. | |
| bFileUrl | No | URL of the b-file the terms came from; absent when source is data. | |
| truncated | No | True when nextFromIndex is set. | |
| nextFromIndex | No | Pass as fromIndex for the next slice. Absent when no slice follows this one: the terms ended, or the notice says how to reach the rest. | |
| bFileSizeInBytes | No | Full size of the b-file as OEIS reported it; absent when not reported. | |
| lastAvailableIndex | No | Highest index n read so far for this entry; when bFileCut is true the b-file may contain terms beyond it. Absent when no terms were read. | |
| firstAvailableIndex | No | Lowest index n read for this entry; absent when no terms were read. |