Enhancements
- Added
ToolCallParser
s -- these classes are wrappers around KaniEngine
s that parse raw text generated by a model, and return Kani-format tool calls. This is an easy way to enable tool calling on open-source models!
Example:
from kani.engines.huggingface import HuggingEngine
from kani.prompts.impl.mistral import MISTRAL_V3_PIPELINE
from kani.tool_parsers.mistral import MistralToolCallParser
model = HuggingEngine(model_id="mistralai/Mistral-Small-Instruct-2409", prompt_pipeline=MISTRAL_V3_PIPELINE)
engine = MistralToolCallParser(model)
- Added
NaiveJSONToolCallParser
(e.g., Llama 3) - Added
MistralToolCallParser
- Added
DeepseekR1ToolCallParser
Bug Fixes et al.
- Fix compatibility issues with Pydantic 2.10
- Update documentation to better reflect supported HF models