@h1r-ai/croche 0.5.0 → 0.5.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.
Files changed (35) hide show
  1. package/README.md +21 -13
  2. package/dist/core-bindgen.js +18 -18
  3. package/dist/core-runtime.d.ts +1 -1
  4. package/dist/core-runtime.js +1 -1
  5. package/dist/core-wasm-bytes.d.ts +3 -3
  6. package/dist/core-wasm-bytes.js +3 -3
  7. package/dist/project-types.d.ts +2 -2
  8. package/dist/types.d.ts +5 -7
  9. package/docs/CODING-AGENT.md +11 -7
  10. package/docs/SKILL.md +307 -265
  11. package/docs/skills/croche/agents/openai.yaml +4 -0
  12. package/docs/skills/croche/references/agents.md +78 -0
  13. package/docs/skills/croche/references/first-turn.md +74 -0
  14. package/docs/skills/croche/references/tools.md +43 -0
  15. package/docs/skills/croche-cli/SKILL.md +158 -0
  16. package/docs/skills/croche-cli/agents/openai.yaml +4 -0
  17. package/docs/skills/croche-cli/references/powershell.md +47 -0
  18. package/docs/skills/croche-config/SKILL.md +152 -0
  19. package/docs/skills/croche-config/agents/openai.yaml +4 -0
  20. package/docs/skills/croche-config/references/models.md +12 -0
  21. package/docs/skills/croche-platforms/SKILL.md +55 -0
  22. package/docs/skills/croche-platforms/agents/openai.yaml +4 -0
  23. package/docs/skills/croche-platforms/references/android.md +185 -0
  24. package/docs/skills/croche-platforms/references/ios.md +165 -0
  25. package/docs/skills/croche-platforms/references/react-native.md +50 -0
  26. package/docs/skills/croche-platforms/references/web-backend.md +58 -0
  27. package/docs/skills/croche-troubleshoot/SKILL.md +72 -0
  28. package/docs/skills/croche-troubleshoot/agents/openai.yaml +4 -0
  29. package/docs/skills/croche-troubleshoot/references/recovery.md +31 -0
  30. package/package.json +1 -1
  31. package/src/core-bindgen.ts +18 -18
  32. package/src/core-runtime.ts +1 -1
  33. package/src/core-wasm-bytes.ts +3 -3
  34. package/src/project-types.ts +2 -2
  35. package/src/types.ts +5 -7
@@ -56,8 +56,8 @@ export interface OpenOptions extends Pick<HostOptions,
56
56
  'requestTimeoutMs' | 'maxPendingEvents' | 'archive' | 'imageCodec' | 'fetch' | 'clock' |
57
57
  'syncIntervalMs' | 'maintenanceBackoffMs' | 'streaming'> {
58
58
  user?: string;
59
- /** The app's preferred language for this user; browser defaults to navigator.language,
60
- * otherwise config.defaultLanguage ("en" when omitted). Never inferred from user text. */
59
+ /** The user's language; defaults to the device locale (browser navigator.language, React Native
60
+ * the device locale), otherwise config.defaultLanguage ("en" when omitted). Never inferred from user text. */
61
61
  language?: string;
62
62
  /** Host-only retention budget, copied unchanged; Core owns validation and defaults. */
63
63
  retentionBytes?: number;
package/src/types.ts CHANGED
@@ -199,11 +199,8 @@ export interface HostOptions {
199
199
  }
200
200
 
201
201
  /**
202
- * Everything `CrocheRuntime.create` takes: the app's choices and the host's. Runtime mechanics
203
- * and internal prompt text are Croche settings, not app options: passing one of the
204
- * former options `replyWithCommands`, `actionRecord`, `timeContext`, `contextDeltas`,
205
- * `temperature` or `memory.recall` fails with `invalid_configuration`. App `reasoning` is
206
- * accepted: `default`, `off`, `low`, `medium` or `high`.
202
+ * Single-agent app and host options. Unknown configuration properties fail with
203
+ * `invalid_configuration`. App `reasoning` accepts `default`, `off`, `low`, `medium` or `high`.
207
204
  */
208
205
  export type RuntimeOptions = AppOptions & HostOptions;
209
206
 
@@ -604,8 +601,9 @@ export interface RuntimeDebugEvent {
604
601
  export type SendInput = {
605
602
  /** Immutable application message identity, retained across delivery retries. */
606
603
  id: string;
607
- /** Current trusted app state. Kept earlier turns are resent exactly as they were sent, earlier
608
- * states included. Send the current state on every message, even when unchanged: Croche sends only what changed, and resends it in full after older turns are folded. */
604
+ /** Optional app state, separate from the person's words. Useful when the request needs it,
605
+ * such as a command or button acting on app data, or after that state changed. Without it,
606
+ * this input carries only the message; earlier states stay as sent until older turns are folded. */
609
607
  context?: JsonValue;
610
608
  } & ({ text: string; kind?: 'user' | 'event'; images?: InputImage[]; inputs?: never } | { inputs: StackedInput[]; text?: never; kind?: never; images?: never });
611
609