Package large-language-models
LlmReasoningDemo #sleela 3.0 (lib/large-language-models/examples/LlmReasoningDemo.sleela)
LlmReasoningDemo class
A runnable demo of the large-language-models package: declares a model capacity, derives a reasoning budget, configures the reasoning layer with the SLeeLa code verifier as its symbolic half, and shows the UNKNOWN-never-promoted commit policy. Sibling .sleela files in this package are auto-linked by the runner.
Methods — the actions this unit can perform.
| Method | Signature | What it does |
|---|---|---|
main | void main() | No description in source. |
SLLlmBaseVocabulary #sleela 3.0 (lib/large-language-models/SLLlmBaseVocabulary.sleela)
SLLlmBaseVocabulary class
SLeeLa mirror of the base/seed vocabulary loader (sllmbv_ in large_language_models_base_vocabulary.h). It populates an empty vocabulary store with the compiled-in "sleela-base-en-1.0" table: ten special tokens at fixed low ids (pad=0 .. tool=9), then ordinary tokens from id 10. It builds only the token-id table and never imports dictionary definitions, and it fails closed if a token does not land at its declared id.
Fields — the named values this unit stores.
| Field | Declaration | What it holds |
|---|---|---|
ROLE_PAD | static final int ROLE_PAD = 0 | sllmbv_role mirror: the fixed low ids of the special tokens. |
ROLE_UNK | static final int ROLE_UNK = 1 | No description in source. |
ROLE_BOS | static final int ROLE_BOS = 2 | No description in source. |
ROLE_EOS | static final int ROLE_EOS = 3 | No description in source. |
ROLE_SEP | static final int ROLE_SEP = 4 | No description in source. |
ROLE_MASK | static final int ROLE_MASK = 5 | No description in source. |
ROLE_SYSTEM | static final int ROLE_SYSTEM = 6 | No description in source. |
ROLE_USER | static final int ROLE_USER = 7 | No description in source. |
ROLE_ASSISTANT | static final int ROLE_ASSISTANT = 8 | No description in source. |
ROLE_TOOL | static final int ROLE_TOOL = 9 | No description in source. |
ROLE_RESERVED | static final int ROLE_RESERVED = 10 | No description in source. |
ROLE_COUNT | static final int ROLE_COUNT = 11 | No description in source. |
STATUS_OK | static final int STATUS_OK = 0 | sllmbv_status mirror. |
STATUS_INVALID_ARGUMENT | static final int STATUS_INVALID_ARGUMENT = 1 | No description in source. |
STATUS_OUT_OF_MEMORY | static final int STATUS_OUT_OF_MEMORY = 2 | No description in source. |
STATUS_PARSE_ERROR | static final int STATUS_PARSE_ERROR = 3 | No description in source. |
STATUS_ID_MISMATCH | static final int STATUS_ID_MISMATCH = 4 | No description in source. |
STATUS_DUPLICATE_TOKEN | static final int STATUS_DUPLICATE_TOKEN = 5 | No description in source. |
STATUS_ROLE_UNSET | static final int STATUS_ROLE_UNSET = 6 | No description in source. |
NO_ID | static final int NO_ID = -1 | SLLMBV_NO_ID sentinel for an undeclared role. |
vocabularyId | String vocabularyId = "sleela-base-en-1.0" | No description in source. |
Methods — the actions this unit can perform.
| Method | Signature | What it does |
|---|---|---|
specialTokenFor | String specialTokenFor(int role) | The ten special tokens, declaration order == role id order. |
loadDefault | int loadDefault(SLLlmVocabulary vocab) | No description in source. |
specialId | int specialId(int role) | sllmbv_special_id: resolve a role to its id, or NO_ID. |
defaultVocabularyId | String defaultVocabularyId() | No description in source. |
statusString | String statusString(int status) | No description in source. |
available | boolean available() | No description in source. |
SLLlmCapacity #sleela 3.0 (lib/large-language-models/SLLlmCapacity.sleela)
SLLlmCapacity class
SLeeLa mirror of the model-capacity profile (sllmc_ in large_language_models_capacity.h). A user-owned declaration of a model's size within a 2..16 GB envelope that derives a reasoning budget scaled to the tier. The envelope bounds are advisory guardrails: out-of-range values clamp and are reported, never refused. It ships no weights and picks no model.
Fields — the named values this unit stores.
| Field | Declaration | What it holds |
|---|---|---|
MIN_BYTES | static final long MIN_BYTES = 2147483648 | Envelope bounds in bytes: 2 GiB .. 16 GiB. |
MAX_BYTES | static final long MAX_BYTES = 17179869184 | No description in source. |
TIER_UNKNOWN | static final int TIER_UNKNOWN = 0 | sllmc_tier mirror. |
TIER_COMPACT | static final int TIER_COMPACT = 1 | No description in source. |
TIER_STANDARD | static final int TIER_STANDARD = 2 | No description in source. |
TIER_CAPABLE | static final int TIER_CAPABLE = 3 | No description in source. |
TIER_LARGE | static final int TIER_LARGE = 4 | No description in source. |
STATUS_OK | static final int STATUS_OK = 0 | sllmc_status mirror (advisory). |
STATUS_INVALID_ARGUMENT | static final int STATUS_INVALID_ARGUMENT = 1 | No description in source. |
STATUS_BELOW_MIN | static final int STATUS_BELOW_MIN = 2 | No description in source. |
STATUS_ABOVE_MAX | static final int STATUS_ABOVE_MAX = 3 | No description in source. |
modelId | String modelId | sllmc_profile fields. |
weightFormat | String weightFormat | No description in source. |
weightBytes | long weightBytes | No description in source. |
contextTokens | int contextTokens | No description in source. |
ramBudgetBytes | long ramBudgetBytes | No description in source. |
accelerated | boolean accelerated | No description in source. |
Methods — the actions this unit can perform.
| Method | Signature | What it does |
|---|---|---|
initProfile | void initProfile() | sllmc_profile_init: STANDARD / ~4 GB defaults. |
tierForBytes | int tierForBytes(long bytes) | No description in source. |
profileCheck | int profileCheck() | sllmc_profile_check: advisory below-min / above-max reporting. |
budgetMaxStepsForTier | int budgetMaxStepsForTier(int tier) | sllmc_derive_budget: max_steps for the declared tier (budget knob subset). |
budgetContextTokensForTier | int budgetContextTokensForTier(int tier) | No description in source. |
tierName | String tierName(int tier) | No description in source. |
statusString | String statusString(int status) | No description in source. |
available | boolean available() | No description in source. |
SLLlmCodeModel #sleela 3.0 (lib/large-language-models/SLLlmCodeModel.sleela)
SLLlmCodeModel class
SLeeLa mirror of the Code LLM profile (sllmcx_ in large_language_models_code.h). Declares a user-owned procedural code model and the contract by which its proposals (summaries, dry-run state, refactorings) are verified by a caller-supplied compiler/test/tracer. It composes with the capacity profile and the reasoning layer's CODE subject.
Fields — the named values this unit stores.
| Field | Declaration | What it holds |
|---|---|---|
LANG_C | static final int LANG_C = 0 | sllmcx_language mirror. |
LANG_FORTRAN | static final int LANG_FORTRAN = 1 | No description in source. |
LANG_PASCAL | static final int LANG_PASCAL = 2 | No description in source. |
LANG_PYTHON | static final int LANG_PYTHON = 3 | No description in source. |
LANG_SHELL | static final int LANG_SHELL = 4 | No description in source. |
LANG_SLEELA | static final int LANG_SLEELA = 5 | No description in source. |
LANG_OTHER | static final int LANG_OTHER = 6 | No description in source. |
TASK_SUMMARIZE | static final int TASK_SUMMARIZE = 1 | sllmcx_task bit flags. |
TASK_DRY_RUN | static final int TASK_DRY_RUN = 2 | No description in source. |
TASK_REFACTOR | static final int TASK_REFACTOR = 4 | No description in source. |
TASK_TRANSLATE | static final int TASK_TRANSLATE = 8 | No description in source. |
TASK_DEBUG | static final int TASK_DEBUG = 16 | No description in source. |
TASK_COMPLETE | static final int TASK_COMPLETE = 32 | No description in source. |
CHECK_NONE | static final int CHECK_NONE = 0 | sllmcx_check_mode mirror: strength of verification. NONE keeps claims UNKNOWN. |
CHECK_COMPILE | static final int CHECK_COMPILE = 1 | No description in source. |
CHECK_TEST | static final int CHECK_TEST = 2 | No description in source. |
CHECK_TRACE | static final int CHECK_TRACE = 3 | No description in source. |
STATUS_OK | static final int STATUS_OK = 0 | sllmcx_status mirror. |
STATUS_INVALID_ARGUMENT | static final int STATUS_INVALID_ARGUMENT = 1 | No description in source. |
STATUS_UNSUPPORTED | static final int STATUS_UNSUPPORTED = 2 | No description in source. |
modelId | String modelId | sllmcx_profile fields. |
baseFamily | String baseFamily | No description in source. |
primaryLanguage | int primaryLanguage | No description in source. |
otherLanguage | String otherLanguage | No description in source. |
tasks | int tasks | No description in source. |
checkMode | int checkMode | No description in source. |
fillInMiddle | boolean fillInMiddle | No description in source. |
Methods — the actions this unit can perform.
| Method | Signature | What it does |
|---|---|---|
initProfile | void initProfile() | sllmcx_profile_init: C + summarize+dry-run+refactor+translate + trace + FIM off. |
hasTask | boolean hasTask(int task) | sllmcx_profile_has_task: bitwise membership test. |
languageName | String languageName(int lang) | No description in source. |
languageLabel | String languageLabel() | No description in source. |
checkModeName | String checkModeName(int mode) | No description in source. |
statusString | String statusString(int status) | No description in source. |
available | boolean available() | No description in source. |
SLLlmEngine #sleela 3.0 (lib/large-language-models/SLLlmEngine.sleela)
SLLlmEngine class
SLeeLa mirror of the core LLM engine (sllm_ in artificial-intelligence/large-language-models/large_language_models.h). A thin engine that drives a caller-supplied backend adapter. It bundles no model and no weights: the backend loads/unloads a model id and generates text.
Fields — the named values this unit stores.
| Field | Declaration | What it holds |
|---|---|---|
STATUS_OK | static final int STATUS_OK = 0 | sllm_status mirror: the fail-closed status codes returned by the C engine. |
STATUS_ERROR_INVALID_ARGUMENT | static final int STATUS_ERROR_INVALID_ARGUMENT = 1 | No description in source. |
STATUS_ERROR_OUT_OF_MEMORY | static final int STATUS_ERROR_OUT_OF_MEMORY = 2 | No description in source. |
STATUS_ERROR_BACKEND | static final int STATUS_ERROR_BACKEND = 3 | No description in source. |
STATUS_ERROR_NOT_LOADED | static final int STATUS_ERROR_NOT_LOADED = 4 | No description in source. |
STATUS_ERROR_CANCELLED | static final int STATUS_ERROR_CANCELLED = 5 | No description in source. |
STATUS_ERROR_UNSUPPORTED | static final int STATUS_ERROR_UNSUPPORTED = 6 | No description in source. |
backendName | String backendName | No description in source. |
loaded | boolean loaded | No description in source. |
modelId | String modelId | No description in source. |
Methods — the actions this unit can perform.
| Method | Signature | What it does |
|---|---|---|
configure | void configure(String backend) | Create the engine over a named backend adapter (sllm_engine_create). |
engineBackendName | String engineBackendName() | No description in source. |
isLoaded | boolean isLoaded() | No description in source. |
loadModel | int loadModel(String id) | sllm_engine_load: the backend loads a model by id. |
unloadModel | int unloadModel() | sllm_engine_unload: release the loaded model. |
statusString | String statusString(int status) | Human-readable status text, mirroring sllm_status_string. |
available | boolean available() | No description in source. |
SLLlmGenerationOptions #sleela 3.0 (lib/large-language-models/SLLlmGenerationOptions.sleela)
SLLlmGenerationOptions class
SLeeLa mirror of sllm_generation_options (the decoding knobs the core engine passes to a backend's generate()): max new tokens, temperature, top-p nucleus cutoff, and a deterministic seed.
Fields — the named values this unit stores.
| Field | Declaration | What it holds |
|---|---|---|
maxNewTokens | int maxNewTokens | No description in source. |
temperature | double temperature | No description in source. |
topP | double topP | No description in source. |
seed | long seed | No description in source. |
Methods — the actions this unit can perform.
| Method | Signature | What it does |
|---|---|---|
initDefaults | void initDefaults() | sllm_generation_options_init: the neutral defaults the C API seeds. |
getMaxNewTokens | int getMaxNewTokens() | No description in source. |
setMaxNewTokens | void setMaxNewTokens(int v) | No description in source. |
getTemperature | double getTemperature() | No description in source. |
setTemperature | void setTemperature(double v) | No description in source. |
getTopP | double getTopP() | No description in source. |
setTopP | void setTopP(double v) | No description in source. |
getSeed | long getSeed() | No description in source. |
setSeed | void setSeed(long v) | No description in source. |
available | boolean available() | No description in source. |
SLLlmLoader #sleela 3.0 (lib/large-language-models/SLLlmLoader.sleela)
SLLlmLoader class
SLeeLa mirror of the loader/handler idiom (sllme_ in loader/example_loader.h). A user implements an encode() handler that turns their own class (words, maths, objects) into a fixed-width feature/target pair; the framework owns bounded buffers, deterministic ordering, and fail-closed validation. It is careful by construction: a non-encodable item is SKIPped (counted) or ERRORs the load -- it never fabricates data.
Fields — the named values this unit stores.
| Field | Declaration | What it holds |
|---|---|---|
STATUS_OK | static final int STATUS_OK = 0 | sllme_status mirror. |
STATUS_INVALID_ARGUMENT | static final int STATUS_INVALID_ARGUMENT = 1 | No description in source. |
STATUS_WIDTH_MISMATCH | static final int STATUS_WIDTH_MISMATCH = 2 | No description in source. |
STATUS_HANDLER_ERROR | static final int STATUS_HANDLER_ERROR = 3 | No description in source. |
STATUS_EMPTY | static final int STATUS_EMPTY = 4 | No description in source. |
ITEM_OK | static final int ITEM_OK = 0 | sllme_item_result mirror. |
ITEM_SKIP | static final int ITEM_SKIP = 1 | No description in source. |
ITEM_ERROR | static final int ITEM_ERROR = 2 | No description in source. |
featureWidth | int featureWidth | Handler shape: fixed feature/target widths. |
targetWidth | int targetWidth | No description in source. |
seen | int seen | Report counters (sllme_report). |
loaded | int loaded | No description in source. |
skipped | int skipped | No description in source. |
Methods — the actions this unit can perform.
| Method | Signature | What it does |
|---|---|---|
configure | void configure(int fWidth, int tWidth) | No description in source. |
resetReport | void resetReport() | No description in source. |
validate | int validate() | sllme_validate: fail closed on non-positive widths. |
accountFor | int accountFor(int itemResult) | No description in source. |
finishReport | int finishReport() | sllme_load_array summary: STATUS_EMPTY if nothing was loaded at all. |
getSeen | int getSeen() | No description in source. |
getLoaded | int getLoaded() | No description in source. |
getSkipped | int getSkipped() | No description in source. |
statusString | String statusString(int status) | No description in source. |
available | boolean available() | No description in source. |
SLLlmParametry #sleela 3.0 (lib/large-language-models/SLLlmParametry.sleela)
SLLlmParametry class
SLeeLa mirror of parametry (sllmp_ in parametry/parametry.h): binds a SLeeLa LLM or neural net to a model that is either KNOWN by name (in the built-in registry) or LOCAL by path. A known name fills the declared parameters (caller overrides where nonzero); a local path takes the caller's declared parameters as-is; neither resolves and the binding fails closed. It ships the registry of known NAMES and declared parameters only, never weights.
Fields — the named values this unit stores.
| Field | Declaration | What it holds |
|---|---|---|
KIND_LLM | static final int KIND_LLM = 0 | sllmp_kind mirror. |
KIND_NEURAL_NET | static final int KIND_NEURAL_NET = 1 | No description in source. |
SOURCE_UNSET | static final int SOURCE_UNSET = 0 | sllmp_source mirror. |
SOURCE_KNOWN | static final int SOURCE_KNOWN = 1 | No description in source. |
SOURCE_LOCAL | static final int SOURCE_LOCAL = 2 | No description in source. |
STATUS_OK | static final int STATUS_OK = 0 | sllmp_status mirror. |
STATUS_INVALID_ARGUMENT | static final int STATUS_INVALID_ARGUMENT = 1 | No description in source. |
STATUS_UNKNOWN_MODEL | static final int STATUS_UNKNOWN_MODEL = 2 | No description in source. |
STATUS_NO_SOURCE | static final int STATUS_NO_SOURCE = 3 | No description in source. |
STATUS_KIND_MISMATCH | static final int STATUS_KIND_MISMATCH = 4 | No description in source. |
STATUS_UNSUPPORTED | static final int STATUS_UNSUPPORTED = 5 | No description in source. |
kind | int kind | The resolved binding (sllmp_parameters) populated by resolve(). |
source | int source | No description in source. |
nameOrPath | String nameOrPath | No description in source. |
weightBytes | long weightBytes | No description in source. |
contextTokens | int contextTokens | No description in source. |
weightFormat | String weightFormat | No description in source. |
Methods — the actions this unit can perform.
| Method | Signature | What it does |
|---|---|---|
resolveBinding | int resolveBinding(int bindingKind, String name, String localPath, | No description in source. |
kindName | String kindName(int k) | No description in source. |
sourceName | String sourceName(int s) | No description in source. |
statusString | String statusString(int status) | No description in source. |
available | boolean available() | No description in source. |
SLLlmReasoning #sleela 3.0 (lib/large-language-models/SLLlmReasoning.sleela)
SLLlmReasoning class
SLeeLa mirror of the Reasoning Language Model layer (sllmr_ in large_language_models_reasoning.h). A neuro-symbolic chain-of-thought controller over a plain LLM engine plus an optional verifier. It decomposes a question, proposes steps, reflects, verifies each step, backtracks on refuted paths, and commits an answer only when the require-verified policy is met. UNKNOWN is never promoted to verified. It bundles no model.
Fields — the named values this unit stores.
| Field | Declaration | What it holds |
|---|---|---|
STATUS_OK | static final int STATUS_OK = 0 | sllmr_status mirror. |
STATUS_INVALID_ARGUMENT | static final int STATUS_INVALID_ARGUMENT = 1 | No description in source. |
STATUS_OUT_OF_MEMORY | static final int STATUS_OUT_OF_MEMORY = 2 | No description in source. |
STATUS_BACKEND_ERROR | static final int STATUS_BACKEND_ERROR = 3 | No description in source. |
STATUS_NOT_LOADED | static final int STATUS_NOT_LOADED = 4 | No description in source. |
STATUS_CANCELLED | static final int STATUS_CANCELLED = 5 | No description in source. |
STATUS_NO_SOUND_PATH | static final int STATUS_NO_SOUND_PATH = 6 | No description in source. |
STATUS_UNSUPPORTED | static final int STATUS_UNSUPPORTED = 7 | No description in source. |
SUBJECT_GENERAL | static final int SUBJECT_GENERAL = 0 | sllmr_subject mirror: controller policies, not separate models. |
SUBJECT_MATH | static final int SUBJECT_MATH = 1 | No description in source. |
SUBJECT_PHILOSOPHY | static final int SUBJECT_PHILOSOPHY = 2 | No description in source. |
SUBJECT_RELIGION | static final int SUBJECT_RELIGION = 3 | No description in source. |
SUBJECT_CODE | static final int SUBJECT_CODE = 4 | No description in source. |
STEP_DECOMPOSE | static final int STEP_DECOMPOSE = 0 | sllmr_step_kind mirror. |
STEP_ASSUMPTION | static final int STEP_ASSUMPTION = 1 | No description in source. |
STEP_DEDUCTION | static final int STEP_DEDUCTION = 2 | No description in source. |
STEP_INDUCTION | static final int STEP_INDUCTION = 3 | No description in source. |
STEP_OBJECTION | static final int STEP_OBJECTION = 4 | No description in source. |
STEP_REFLECTION | static final int STEP_REFLECTION = 5 | No description in source. |
STEP_REVISION | static final int STEP_REVISION = 6 | No description in source. |
STEP_CONCLUSION | static final int STEP_CONCLUSION = 7 | No description in source. |
VERDICT_UNKNOWN | static final int VERDICT_UNKNOWN = 0 | sllmr_verdict mirror. |
VERDICT_SUPPORTED | static final int VERDICT_SUPPORTED = 1 | No description in source. |
VERDICT_REFUTED | static final int VERDICT_REFUTED = 2 | No description in source. |
subject | int subject | sllmr_options fields. |
maxSteps | int maxSteps | No description in source. |
maxBacktracks | int maxBacktracks | No description in source. |
reflectionEvery | int reflectionEvery | No description in source. |
minConfidence | double minConfidence | No description in source. |
requireVerified | boolean requireVerified | No description in source. |
seed | long seed | No description in source. |
verifierName | String verifierName | No description in source. |
hasVerifier | boolean hasVerifier | No description in source. |
Methods — the actions this unit can perform.
| Method | Signature | What it does |
|---|---|---|
initOptions | void initOptions() | sllmr_options_init: neutral reasoning defaults. |
configure | void configure(String verifier) | sllmr_engine_create: bind an optional symbolic verifier by name. |
engineVerifierName | String engineVerifierName() | No description in source. |
subjectName | String subjectName(int s) | No description in source. |
stepKindName | String stepKindName(int k) | No description in source. |
verdictName | String verdictName(int v) | No description in source. |
stepCommittable | boolean stepCommittable(int verdict) | Policy gate mirroring the C commit rule: a step is committable only if its verdict is not REFUTED, and when require-verified holds it must be SUPPORTED. UNKNOWN is never promoted to verified. |
statusString | String statusString(int status) | No description in source. |
available | boolean available() | No description in source. |
SLLlmSleelaVerifier #sleela 3.0 (lib/large-language-models/SLLlmSleelaVerifier.sleela)
SLLlmSleelaVerifier class
SLeeLa mirror of the SLeeLa code verifier (sllmsl_ in sleela/sleela_code_verifier.h). A fast static checker that encodes SLeeLa's real rules from SLEELA.syntax (reserved identifiers, the no-arg close() collision, C-style comments, multi-line single-angle comments, inline angle comments, apostrophe-in-comment, the 64-field cap, and the missing-metadata advisory). It plugs into the reasoning layer as the symbolic half so bad code proposals are refuted and backtracked. It does not shell out to the real compiler.
Fields — the named values this unit stores.
| Field | Declaration | What it holds |
|---|---|---|
RULE_OK | static final int RULE_OK = 0 | sllmsl_rule mirror. |
RULE_RESERVED_IDENTIFIER | static final int RULE_RESERVED_IDENTIFIER = 1 | No description in source. |
RULE_CLOSE_COLLISION | static final int RULE_CLOSE_COLLISION = 2 | No description in source. |
RULE_CSTYLE_COMMENT | static final int RULE_CSTYLE_COMMENT = 3 | No description in source. |
RULE_MULTILINE_ANGLE | static final int RULE_MULTILINE_ANGLE = 4 | No description in source. |
RULE_INLINE_ANGLE | static final int RULE_INLINE_ANGLE = 5 | No description in source. |
RULE_APOSTROPHE_COMMENT | static final int RULE_APOSTROPHE_COMMENT = 6 | No description in source. |
RULE_FIELD_CAP | static final int RULE_FIELD_CAP = 7 | No description in source. |
RULE_MISSING_METADATA | static final int RULE_MISSING_METADATA = 8 | No description in source. |
MAX_FIELDS | static final int MAX_FIELDS = 64 | SL_MAX_STRUCT_FIELDS: the layout cap the VM admits per class/struct. |
VERDICT_UNKNOWN | static final int VERDICT_UNKNOWN = 0 | sllmr_verdict values the reasoning layer expects back from a verifier. |
VERDICT_SUPPORTED | static final int VERDICT_SUPPORTED = 1 | No description in source. |
VERDICT_REFUTED | static final int VERDICT_REFUTED = 2 | No description in source. |
treatMissingMetadataAsError | boolean treatMissingMetadataAsError | No description in source. |
Methods — the actions this unit can perform.
| Method | Signature | What it does |
|---|---|---|
initOptions | void initOptions() | No description in source. |
isReservedWord | boolean isReservedWord(String word) | No description in source. |
isCloseCollision | boolean isCloseCollision(String methodName, int paramCount) | No description in source. |
ruleName | String ruleName(int rule) | No description in source. |
verdictForFinding | int verdictForFinding(int rule) | No description in source. |
exceedsFieldCap | boolean exceedsFieldCap(int fieldCount) | Does a class with this many instance fields exceed the VM layout cap? |
available | boolean available() | No description in source. |
SLLlmVocabulary #sleela 3.0 (lib/large-language-models/SLLlmVocabulary.sleela)
SLLlmVocabulary class
SLeeLa mirror of the token-ID vocabulary store (sllmv_ in large_language_models_vocabulary.h). Token ids are stable insertion-order indices; tokens are exact, non-empty UTF-8. encode() splits on whitespace and preserves punctuation as part of each token.
Fields — the named values this unit stores.
| Field | Declaration | What it holds |
|---|---|---|
STATUS_OK | static final int STATUS_OK = 0 | sllmv_status mirror. |
STATUS_INVALID_ARGUMENT | static final int STATUS_INVALID_ARGUMENT = 1 | No description in source. |
STATUS_OUT_OF_MEMORY | static final int STATUS_OUT_OF_MEMORY = 2 | No description in source. |
STATUS_NOT_FOUND | static final int STATUS_NOT_FOUND = 3 | No description in source. |
STATUS_BUFFER_TOO_SMALL | static final int STATUS_BUFFER_TOO_SMALL = 4 | No description in source. |
tokens | String[] tokens | The token table. Parallel arrays keep this portable across SLeeLa targets. |
count | int count | No description in source. |
capacity | int capacity | No description in source. |
Methods — the actions this unit can perform.
| Method | Signature | What it does |
|---|---|---|
configure | void configure(int cap) | No description in source. |
size | int size() | No description in source. |
add | int add(String token) | sllmv_vocabulary_add: append a token, return its stable id (= prior count). |
grow | void grow() | No description in source. |
find | int find(String token) | sllmv_vocabulary_find: return the id for a token, or -1 if absent. |
tokenAt | String tokenAt(int id) | sllmv_vocabulary_token: return the token for an id, or null if out of range. |
available | boolean available() | No description in source. |
SLPackage #sleela 3.0 (lib/large-language-models/SLPackage.sleela)
SLPackage class
Defines the SLeeLa standard-library package for large-language-models.
Fields — the named values this unit stores.
| Field | Declaration | What it holds |
|---|---|---|
packageName | String packageName | No description in source. |
Methods — the actions this unit can perform.
| Method | Signature | What it does |
|---|---|---|
configure | void configure(String name) | No description in source. |
name | String name() | No description in source. |
available | boolean available() | No description in source. |