Skip to main content
Hyperterse ships five role-based JSON Schema files for editor-time validation, autocompletion, and inline documentation.
Schema fileTarget filesPurpose
schema/root.terse.schema.json.hyperterseRoot service configuration
schema/adapter.terse.schema.jsonapp/adapters/*.terseAdapter definitions
schema/tool.terse.schema.jsonapp/tools/*/config.terseTool definitions
schema/prompt.terse.schema.jsonapp/prompts/**/*.tersePrompt definitions
schema/resource.terse.schema.jsonapp/resources/**/config.terseResource and resource-template settings

Generation

Schemas are generated from the project’s source schema definitions:
make generate
The generator reads connector and primitive type enums and emits JSON Schema files with the correct enum constraints.

Editor setup

Point your editor at the schema files to enable autocompletion, hover docs, and inline validation for .terse files.

VS Code / Cursor

Add to .vscode/settings.json:
{
  "yaml.schemas": {
    "schema/root.terse.schema.json": "**/.hyperterse",
    "schema/adapter.terse.schema.json": "**/adapters/*.terse",
    "schema/tool.terse.schema.json": "**/tools/**/config.terse",
    "schema/prompt.terse.schema.json": "**/prompts/**/*.terse",
    "schema/resource.terse.schema.json": "**/resources/**/config.terse"
  }
}
Requires the YAML extension.

JetBrains IDEs

Settings → Languages & Frameworks → Schemas and DTDs → JSON Schema Mappings. Add one mapping per schema with the appropriate file pattern.

Schema highlights

Each schema enforces required fields, value constraints, and structural rules for its configuration level.

Root (root.terse.schema.json)

  • name — Required. Pattern: ^[a-z][a-z0-9_-]*$.
  • version — Optional string.
  • root — String (default discovery root: app).
  • tools.directory — String (default: tools).
  • tools.cacheenabled (boolean), ttl (integer).
  • tools.search.limit — Integer (default: 10) controlling max MCP search results.
  • adapters.directory — String (default: adapters).
  • prompts — Either:
    • { directory: string } discovery config (default: prompts), or
    • inline prompt definitions array.
  • resources — Either:
    • { directory: string } discovery config (default: resources), or
    • inline concrete resource definitions array.
  • resource_templates — Optional inline resource-template definitions array.
  • server.port — Integer or string.
  • server.log_level — Integer, 1–4.
  • build.out / build.out_dir — String.
  • build.clean_dir — Boolean.

Adapter (adapter.terse.schema.json)

  • connector — Required. Enum: postgres, redis, mysql, mongodb, sqlite.
  • connection_string — Required string.
  • name — Optional.
  • options — Optional map.

Tool (tool.terse.schema.json)

  • description — Required string.
  • use — String.
  • statement — String.
  • inputs — Map of typed definitions.
  • handler — Optional script handler path (path#exportName supported; defaults to export default).
  • mappers — Optional input / output mapper paths (path#exportName supported; defaults to export default).
  • authplugin, policy.
  • cacheenabled, ttl.
  • Constraint: exactly one of use or handler is required (enforced via oneOf).

Prompt (prompt.terse.schema.json)

  • name — Optional prompt name override (defaults to filename).
  • title — Optional string.
  • description — Optional string.
  • arguments — Optional map keyed by argument name with:
    • title (string)
    • description (string)
    • required (boolean)
    • completion (string array)
  • messages — Required non-empty array of { role, text } where role is one of user, assistant, system.
See Prompt configuration.

Resource (resource.terse.schema.json)

  • Supports both concrete resources and URI templates in one schema.
  • Shared optional fields: name, title, description, mime_type.
  • Concrete resource mode:
    • uri (required)
    • one of text or file (required)
  • Resource template mode:
    • uri_template (required)
    • one of text_template or file_template (required)
    • optional arguments map keyed by argument name with:
      • title (string)
      • description (string)
      • required (boolean)
      • completion (string array)
See Resource configuration.

Keeping schemas in sync

When configuration shapes change, schemas and documentation must update in the same change:
  1. Regenerate schema artifacts in schema/.
  2. Update field definitions in reference documentation.
  3. Update .vscode/settings.json globs if file-role matching changed.
  4. Verify checklists/reference docs include all current schema files:
    • root.terse.schema.json
    • adapter.terse.schema.json
    • tool.terse.schema.json
    • prompt.terse.schema.json
    • resource.terse.schema.json