Engineering / AI Systems

Tools That Help AI Coding Assistants Write Jac

A Model Context Protocol (MCP) server that gives AI coding assistants Jac documentation and examples, with smaller tool sets for smaller models.

Problem AI coding assistants know little about Jac, a new language, and in my app-building runs smaller models struggled when shown every tool at once.

agentMCPcontext + toolsfullstandardlite
Schematic

Overview

Jac is an open-source, Python-like programming language from Jaseci Labs. The Model Context Protocol (MCP) is a standard way for an AI coding assistant to call tools and read documents supplied by a server. Jac is almost absent from model training data, so this server is the agent’s main reference for the language. I worked on the Jac MCP server and on MCP client support inside ByLLM, Jac’s library for calling language models.

Problem

Two observations from building applications with agents, recorded in jac-mcp-devkit, shaped this work:

  1. Agents made Jac-specific mistakes, such as confusing root with root() and misreading how walker results are returned.
  2. Smaller models seemed to do worse when shown the full set of tools and prompts at once. This was an observation from those runs, not a measured result.

What I built

  • Tools and a knowledge map (#5298, #5362). A map of Jac and Jaseci concepts, plus tools that fetch the matching documentation and examples for the agent.
  • Lazy example loading (#5216). Examples are fetched from GitHub only when accessed, local examples take priority, and GitHub categories are cached, which keeps resource indexing fast.
  • MCP client support in ByLLM (#5474). Jac programs that call LLMs can themselves consume MCP tools.
  • A mode framework (#5682). A mode setting with three tiers, lite, standard and full, gates which tools and prompts the server exposes.

Key engineering decision

The mode framework added the setting first and left the tool assignments for later. full is the default and keeps the existing behaviour. lite and standard initially expose the same tools as full, and the per-mode exclusion lists were left for follow-up changes once the assignments were decided. Existing users saw no change, and the later per-mode limits only need edits to those lists.

Evidence

All engineering