Cette page est affichée en anglais. Une traduction française est en cours.
ScriptsMay 11, 2026·2 min de lecture

TypeChat — Schema-First Natural Language UIs

Build typed natural language interfaces by turning intent into validated JSON via TypeScript types. Replace prompt engineering with schema engineering.

Prêt pour agents

Cet actif peut être lu et installé directement par les agents

TokRepo expose une commande CLI universelle, un contrat d'installation, le metadata JSON, un plan selon l'adaptateur et le contenu raw pour aider les agents à juger l'adaptation, le risque et les prochaines actions.

Stage only · 29/100Stage only
Surface agent
Tout agent MCP/CLI
Type
Script
Installation
Single
Confiance
Confiance : Established
Point d'entrée
README.md
Commande CLI universelle
npx tokrepo install 6722eee5-8afd-4e50-9259-3a3ceb67e74f
Introduction

Build typed natural language interfaces by turning intent into validated JSON via TypeScript types. Replace prompt engineering with schema engineering.

  • Best for: Product teams who need typed actions (APIs, workflows) from an LLM with validation and repair loops
  • Works with: TypeScript/JavaScript, any LLM backend, JSON schema-style validation flows
  • Setup time: 12 minutes

Quantitative Notes

  • Setup time ~12 minutes (npm install + run one example in the repo)
  • GitHub stars + forks (verified): see Source & Thanks
  • Typical loop: generate JSON → validate → repair (1–2 retries)

Practical Notes

If you’re building an agent that triggers actions, define a narrow union type for allowed intents and keep each intent payload minimal. Add deterministic validation (schema + business rules) and log all repairs—repairs are where many hidden bugs appear. Over time, grow the schema set rather than growing prompts.

Safety note: Always validate typed JSON with business rules (not just schema) before executing real actions.

FAQ

Q: Do I still need prompt engineering? A: Much less. You focus on defining types/schemas; prompts become smaller and more stable.

Q: How does it handle invalid JSON? A: It validates and can re-prompt the model to repair non-conforming output.

Q: Is it only for TypeScript apps? A: TypeChat provides TypeScript/JS support, and the repo also references other language variants.


🙏

Source et remerciements

GitHub: https://github.com/microsoft/TypeChat Owner avatar: https://avatars.githubusercontent.com/u/6154722?v=4 License (SPDX): MIT GitHub stars (verified via api.github.com/repos/microsoft/TypeChat): 8,652 GitHub forks (verified via api.github.com/repos/microsoft/TypeChat): 413

Fil de discussion

Connectez-vous pour rejoindre la discussion.
Aucun commentaire pour l'instant. Soyez le premier à partager votre avis.

Actifs similaires