@rsconcept/rstool 0.10.3 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +61 -33
- package/dist/agent-workflow-Gk0Vfnv1.d.ts +64 -0
- package/dist/analysis-LLnPhmGa.d.ts +23 -0
- package/dist/{common-DxLg3eXX.d.ts → common-DHJalS-Q.d.ts} +6 -1
- package/dist/constituenta-DnGR6bnM.d.ts +54 -0
- package/dist/diagnostic-D9yl_mEL.d.ts +19 -0
- package/dist/evaluation-Cns8BFm4.d.ts +31 -0
- package/dist/index.d.ts +11 -11
- package/dist/index.js +1 -2
- package/dist/mappers/model-adapter.d.ts +3 -3
- package/dist/mappers/schema-adapter.d.ts +4 -4
- package/dist/mappers/types.d.ts +6 -2
- package/dist/mappers/types.js +2 -0
- package/dist/mappers/types.js.map +1 -1
- package/dist/{model-value-SFAVj0dw.d.ts → model-value-BbonPzMz.d.ts} +14 -3
- package/dist/models/agent-workflow.d.ts +2 -0
- package/dist/models/agent-workflow.js +1 -0
- package/dist/models/analysis.d.ts +1 -1
- package/dist/models/common.d.ts +1 -1
- package/dist/models/constituenta.d.ts +2 -2
- package/dist/models/diagnostic.d.ts +1 -1
- package/dist/models/evaluation.d.ts +2 -2
- package/dist/models/index.d.ts +11 -11
- package/dist/models/index.js +2 -2
- package/dist/models/model-value.d.ts +2 -2
- package/dist/models/rstool-agent.d.ts +1 -1
- package/dist/models/rstool-agent.js +1 -1
- package/dist/models/session.d.ts +1 -1
- package/dist/models/tool-contract.d.ts +2 -2
- package/dist/models/tool-contract.js +2 -1
- package/dist/models/tool-contract.js.map +1 -1
- package/dist/models-Bw6Uum8i.js +685 -0
- package/dist/models-Bw6Uum8i.js.map +1 -0
- package/dist/rstool-agent-D2cQze_b.d.ts +71 -0
- package/dist/session/session-store.d.ts +18 -5
- package/dist/session/session-store.js +1 -64
- package/dist/{session-BPgsE80c.d.ts → session-ChexW8i7.d.ts} +11 -8
- package/dist/tool-contract-0uRGhEfW.d.ts +164 -0
- package/dist/wrapper/client.d.ts +23 -0
- package/dist/wrapper/client.js +17 -0
- package/dist/wrapper/client.js.map +1 -1
- package/dist/wrapper/stdio-wrapper.js +75 -63
- package/dist/wrapper/stdio-wrapper.js.map +1 -1
- package/docs/CONSTITUENTA.md +2 -2
- package/docs/DIAGNOSTICS.md +6 -5
- package/docs/MODEL-TESTING.md +3 -3
- package/docs/PORTAL-API.md +24 -18
- package/examples/README.md +1 -1
- package/examples/agent-client.ts +11 -41
- package/examples/build-chocolate-nim-rsform.ts +21 -70
- package/examples/chocolate-nim/build-rsform.ts +23 -18
- package/examples/chocolate-nim/build-rsmodel.ts +10 -12
- package/examples/chocolate-nim/rsform-session.json +290 -290
- package/examples/chocolate-nim/rsmodel-session.json +291 -291
- package/examples/expression-bank/bank-constituents.ts +304 -53
- package/examples/expression-bank/build-rsform.ts +19 -16
- package/examples/expression-bank/rsform-session.json +1551 -1551
- package/examples/kinship/build-rsform.ts +23 -18
- package/examples/kinship/build-rsmodel.ts +16 -16
- package/examples/kinship/rsform-session.json +219 -219
- package/examples/kinship/rsmodel-session.json +221 -221
- package/examples/kinship/session.ts +19 -21
- package/examples/movd/build-rsform.ts +23 -18
- package/examples/movd/build-rsmodel.ts +18 -20
- package/examples/movd/rsform-session.json +262 -262
- package/examples/movd/rsmodel-session.json +264 -264
- package/examples/sample/build-rsform.ts +18 -51
- package/examples/sample/build-rsmodel.ts +25 -44
- package/examples/sample/rsform-session.json +10 -7
- package/examples/sample/rsmodel-session.json +36 -33
- package/examples/template-apply/build-rsform.ts +27 -24
- package/examples/template-apply/rsform-session.json +48 -48
- package/package.json +4 -2
- package/skills/rstool-helper/EXAMPLES.md +44 -116
- package/skills/rstool-helper/GUIDE.md +40 -25
- package/skills/rstool-helper/REFERENCE.md +40 -177
- package/src/index.ts +24 -17
- package/src/mappers/portal-adapter.ts +49 -0
- package/src/mappers/types.ts +4 -0
- package/src/models/agent-workflow.ts +66 -0
- package/src/models/analysis.ts +7 -0
- package/src/models/common.ts +7 -0
- package/src/models/constituenta.ts +24 -6
- package/src/models/diagnostic.ts +4 -0
- package/src/models/evaluation.ts +11 -0
- package/src/models/import-detect.test.ts +66 -0
- package/src/models/import-detect.ts +42 -0
- package/src/models/import-export.ts +24 -0
- package/src/models/index.ts +22 -14
- package/src/models/model-value.ts +12 -0
- package/src/models/portal-json.test.ts +38 -0
- package/src/models/portal-json.ts +54 -1
- package/src/models/rstool-agent.test.ts +698 -146
- package/src/models/rstool-agent.ts +392 -92
- package/src/models/session.ts +8 -5
- package/src/models/tool-contract.ts +81 -42
- package/src/session/batch-apply.test.ts +123 -0
- package/src/session/batch-apply.ts +82 -0
- package/src/session/persistence.test.ts +63 -0
- package/src/session/persistence.ts +69 -0
- package/src/session/session-store.ts +76 -6
- package/src/wrapper/client.test.ts +58 -0
- package/src/wrapper/client.ts +23 -0
- package/src/wrapper/stdio-handler.test.ts +101 -0
- package/src/wrapper/stdio-handler.ts +195 -0
- package/src/wrapper/stdio-wrapper.ts +4 -187
- package/dist/analysis-JiwOYDKx.d.ts +0 -16
- package/dist/constituenta-Dnd6iToB.d.ts +0 -36
- package/dist/diagnostic-BMYvciz8.d.ts +0 -15
- package/dist/evaluation-CCVYH0wA.d.ts +0 -21
- package/dist/index-uhkmwruf.d.ts +0 -46
- package/dist/rstool-agent-BZi5jO1y.js +0 -158
- package/dist/rstool-agent-BZi5jO1y.js.map +0 -1
- package/dist/rstool-agent-pRaPnZay.d.ts +0 -35
- package/dist/session/session-store.js.map +0 -1
- package/dist/tool-contract-n1ghUOrK.d.ts +0 -32
package/dist/models/session.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as SessionRevision, r as SessionState, t as SessionHandle } from "../session-
|
|
1
|
+
import { n as SessionRevision, r as SessionState, t as SessionHandle } from "../session-ChexW8i7.js";
|
|
2
2
|
export { SessionHandle, SessionRevision, SessionState };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as RSToolAgentContract, t as CONTRACT_VERSION } from "../tool-contract-
|
|
2
|
-
export { CONTRACT_VERSION, RSToolAgentContract };
|
|
1
|
+
import { n as RSToolAgentContract, r as RSToolAgentOptions, t as CONTRACT_VERSION } from "../tool-contract-0uRGhEfW.js";
|
|
2
|
+
export { CONTRACT_VERSION, RSToolAgentContract, RSToolAgentOptions };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tool-contract.js","names":[],"sources":["../../src/models/tool-contract.ts"],"sourcesContent":["import { type
|
|
1
|
+
{"version":3,"file":"tool-contract.js","names":[],"sources":["../../src/models/tool-contract.ts"],"sourcesContent":["import {\n type ApplySchemaPatchInput,\n type ApplySchemaPatchResult,\n type SessionStateDetail,\n type SessionStateResult\n} from './agent-workflow';\nimport { type AnalysisResult, type AnalyzeExpressionInput } from './analysis';\nimport { type DiagnosticRecord, type ListDiagnosticsFilters } from './diagnostic';\nimport { type EvaluateInput, type EvaluationResult } from './evaluation';\nimport { type ExportPortalInput, type ExportPortalResult, type ImportDataKind } from './import-export';\nimport { type RecalculateModelResult, type SessionModelState, type SetModelValuesInput } from './model-value';\nimport { type SessionHandle, type SessionRevision, type SessionState } from './session';\n\n/** Agent-visible contract version; bump on breaking API changes. */\nexport const CONTRACT_VERSION = '2.0.0';\n\n/** Options for constructing an {@link RSToolAgent}. */\nexport interface RSToolAgentOptions {\n /** When set, sessions are persisted to this directory and survive process restarts. */\n persistenceDir?: string;\n}\n\n/**\n * Public method surface of {@link RSToolAgent}.\n *\n * Each method accepts an optional `sessionId`; when omitted, the current session is used\n * (or a new one is created where noted).\n */\nexport interface RSToolAgentContract {\n /** Current contract version string (same as {@link CONTRACT_VERSION}). */\n readonly contractVersion: string;\n\n /** Return the current session, or create one with optional `initial` metadata. */\n ensureSession(initial?: Partial<SessionState>): SessionHandle;\n\n /** Create a new session and make it current. */\n createSession(initial?: Partial<SessionState>): SessionHandle;\n\n /** Return the current session handle, or `null` when none is active. */\n getCurrentSession(): SessionHandle | null;\n\n /** Switch the active session; throws when `sessionId` is unknown. */\n setCurrentSession(sessionId: string): SessionHandle;\n\n /** Apply constituent patches to the schema (analyze, merge, optionally commit). */\n applySchemaPatch(input: ApplySchemaPatchInput, sessionId?: string): ApplySchemaPatchResult;\n\n /** Return session summary (default) or full cloned state when `detail` is `'full'`. */\n getSessionState(detail?: SessionStateDetail, sessionId?: string): SessionStateResult;\n\n /** List diagnostics for the session, optionally filtered by constituent. */\n listDiagnostics(filters?: ListDiagnosticsFilters, sessionId?: string): DiagnosticRecord[];\n\n /** Parse and type-check an RSLang expression against the current schema context. */\n analyzeExpression(input: AnalyzeExpressionInput, sessionId?: string): AnalysisResult;\n\n /** Record a revision checkpoint with an optional message. */\n commitStep(message?: string, sessionId?: string): SessionRevision;\n\n /** Export the session as a JSON string (state + diagnostics). */\n exportSession(sessionId?: string): string;\n\n /** Export schema or model payload in Portal JSON format. */\n exportPortal(input: ExportPortalInput, sessionId?: string): ExportPortalResult;\n\n /**\n * Import a session export or Portal JSON payload and make the new session current.\n *\n * When `kind` is `'auto'`, the payload shape is detected automatically.\n */\n importData(payload: string | object, kind?: ImportDataKind): SessionHandle;\n\n /** Set or clear model values for constituents; returns the updated model state. */\n setModelValues(input: SetModelValuesInput, sessionId?: string): Promise<SessionModelState>;\n\n /** Return a deep clone of the session model state. */\n getModelState(sessionId?: string): SessionModelState;\n\n /**\n * Evaluate a stored constituent or a scratch expression.\n *\n * Provide `constituentId`, or both `expression` and `cstType`.\n */\n evaluate(input: EvaluateInput, sessionId?: string): EvaluationResult;\n\n /** Recompute derived model values for all constituents. */\n recalculateModel(sessionId?: string): RecalculateModelResult;\n}\n"],"mappings":";;AAcA,MAAa,mBAAmB"}
|