From 9e5f17c7fe535e6f706ecccfd34c83936859d739 Mon Sep 17 00:00:00 2001 From: ochafik Date: Fri, 28 Jun 2024 22:34:39 +0100 Subject: [PATCH] fix typos --- examples/json_schema_to_grammar.mjs | 2 +- grammars/README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/json_schema_to_grammar.mjs b/examples/json_schema_to_grammar.mjs index a181362b8..83a2aa735 100644 --- a/examples/json_schema_to_grammar.mjs +++ b/examples/json_schema_to_grammar.mjs @@ -2,7 +2,7 @@ JSON Schema to Grammar converter (JavaScript version) There are C++ and Python converters w/ the same features. - (More flags are currently exposed for the Python version) + (More flags are currently exposed by the Python version) Usage: node examples/json_schema_to_grammar.mjs schema.json diff --git a/grammars/README.md b/grammars/README.md index 3ca71086b..37fe24c0b 100644 --- a/grammars/README.md +++ b/grammars/README.md @@ -123,7 +123,7 @@ You can use GBNF grammars: - For the `/chat/completions` endpoint, passed inside the `result_format` body field (e.g. `{"type", "json_object", "schema": {"items": {}}}`) - In [llama-cli](../examples/main), passed as the `--json` / `-j` flag - To convert to a grammar ahead of time: - - in CLI, with [`node examples/json_schema_to_grammar.py schema.json`](../examples/json_schema_to_grammar.py) + - in Python with [`python examples/json_schema_to_grammar.py schema.json`](../examples/json_schema_to_grammar.py) - in JavaScript with [`node examples/json_schema_to_grammar.mjs schema.json`](../examples/json_schema_to_grammar.mjs) (uses same lib as the [server](../examples/server)'s Web UI) Take a look at [tests](../tests/test-json-schema-to-grammar.cpp) to see which features are likely supported (you'll also find usage examples in https://github.com/ggerganov/llama.cpp/pull/5978, https://github.com/ggerganov/llama.cpp/pull/6659 & https://github.com/ggerganov/llama.cpp/pull/6555).