v0.9.5 is live! — Read the latest technical documentation and migration guides.

docmd-assistant v0.1.17 makes the assistant engine fully universal and site-agnostic, adds targeted version and subproject search filtering, introduces token-economy content capping for large documentation pages, strengthens context window boundaries, and improves network error resilience.

Key Features & Enhancements

Universal & Site-Agnostic System Prompt

  • Authentic Knowledge Discovery: Replaced hardcoded configuration assumptions with a universal, site-agnostic prompt. Rather than presuming specific configuration schemas, the assistant dynamically discovers and grounds its answers using available tools (search_documentation, read_documentation_page). This ensures it functions naturally across any documentation website, personal blog, or technical guide.
  • Consistent Assistant Identity: Preserves the core “docmd assistant” persona as a helpful AI guide dedicated to the site, answering within the boundaries of available content.
  • Targeted Version Filtering: Extended the search_documentation tool schema with optional version (e.g. "0.9.0", "0.8.0", "latest") and project parameters, allowing multi-version and multi-project doc sites to target specific archives directly.
  • Custom Delegate Passthrough: Custom search providers passed to createStandardTools now receive (query, project, version) arguments for granular index querying.

Smart Content Capping & Context Window Safeguards

  • DOM Reader Token Economy: Added an 8,000-character ceiling with a clean continuation indicator (...[content capped for token economy]) in read_documentation_page. This protects LLM context limits from oversized API specifications while retaining essential explanatory text and code examples.
  • Context Window Safeguard Floor: Configured a 1,000-character minimum floor on contextWindow options, preventing accidental micro-truncation from discarding retrieved documentation context.

Resilient Network Error Handling

  • Actionable Network Messages: Intercepts low-level browser network failures (Failed to fetch, Load failed) in both streaming and non-streaming modes and returns clear, user-friendly diagnostics.
  • Clean Abort Handling: Gracefully handles cancelled requests and AbortError without polluting runtime logs.

Resolved Issues

  • Universal Retrieval: Resolved an issue where hardcoded configuration rules in the default prompt caused the assistant to assume docmd.config.json structures instead of dynamically retrieving the current site’s documented configuration.
  • Version Query Precision: Fixed an issue where versioned queries (e.g. asking for specific historical release notes) could not constrain search scope to a designated version bucket.

Upgrade

npm
pnpm
npm install docmd-assistant@0.1.17
pnpm add docmd-assistant@0.1.17