Archived
radiance 1.0.4
- oh-my-pi works unmodified on every Qwen model. Its requests carry a top-level
preserve_thinking, which was refused as an unknown field; it now reaches the chat template the
way enable_thinking does. Its task tool's `model` parameter is the `not` of every JSON type,
which the 1.0.1 fix did not cover: any `not` that excludes every value is now an argument no
call writes, under every chat template and Flash-Next's declared format.
- Command-line defaults and bounds for what a request leaves out. A flag left unset changes
nothing; /server_info reports the values under request_defaults.
- Sampling: --typical-p, --presence-penalty, --frequency-penalty, --repetition-penalty,
--repeat-last-n, --dry-multiplier, --dry-base, --dry-allowed-length, --dry-penalty-last-n,
--dry-sequence-breakers, --xtc-probability, --xtc-threshold.
- Requests: --default-max-tokens N|auto, --max-tokens-cap, --max-n, --max-queued-requests,
--max-stop-strings, --max-stop-bytes.
- Chat template: --chat-template-kwargs JSON|@FILE sets template variables a request's own
chat_template_kwargs override; --reasoning-format auto|none.
- HTTP: --http-threads, --read-timeout, --write-timeout, --keep-alive-timeout, --max-body-mib,
--retry-after, --no-cors.
- Media: --image-min-pixels, --image-max-pixels, --video-min-pixels, --video-max-pixels,
--video-fps, --video-min-frames, --video-max-frames, --video-max-frame-tokens,
--max-source-pixels.
- Under --reasoning-effort none or minimal, a request that sets enable_thinking true now thinks
instead of having the deployment default override it.
- --temp, --top-p, --min-p and --top-k refuse a value that is not a number instead of reading
it as 0.
This commit is contained in:
1 parent
d008fdb32b
commit
09fb41735b
23 files changed
+2478
-104
No files matched your search
@@ -916,6 +916,37 @@ TEST(an_argument_no_value_satisfies_has_no_arm_in_either_grammar) {
|
||||
CHECK_EQ(g.text, b->prompt().grammar);
|
||||
}
|
||||
|
||||
/* OH-MY-PI 18.6.0's TOOLS AS AN UNMODIFIED CLIENT SENDS THEM (tests/data/chat), descriptions aside.
|
||||
* Its `task` tool spells the optional `model` as the `not` of a union of all six JSON types rather
|
||||
* than `{"not": {}}`, which is `never` all the same; the declared format must give it no arm and
|
||||
* agree with the derived format about the whole tool set, as it does about every other. */
|
||||
TEST(oh_my_pis_tools_build_the_same_grammar_in_either_format) {
|
||||
std::ifstream f(std::string(RAD_CHAT_FIXTURES) + "/oh-my-pi-18.6.0-tools.json");
|
||||
std::ostringstream ss;
|
||||
ss << f.rdbuf();
|
||||
const json tools = json::parse(ss.str());
|
||||
REQUIRE(tools.is_array() && tools.size() == 11);
|
||||
|
||||
RadChatFormat c = qwen_abi();
|
||||
ChatFormat declared;
|
||||
std::string why;
|
||||
CHECK_OK(chat_format_from_abi(&c, &declared, &why));
|
||||
ChatGrammarRequest gq;
|
||||
gq.tools = &tools;
|
||||
ChatGrammar g;
|
||||
CHECK_OK(chat_format_grammar(declared, gq, &g, &why));
|
||||
if (!why.empty()) fprintf(stderr, " %s\n", why.c_str());
|
||||
CHECK(!g.text.empty());
|
||||
CHECK(g.text.find("task-arg-model") == std::string::npos);
|
||||
CHECK(g.text.find("task-arg-tasks") != std::string::npos);
|
||||
|
||||
Bench* b = bench(models()[0], ChatRequest{}, tools);
|
||||
if (!b) return;
|
||||
gq.generation_prompt = b->prompt().generation_prompt;
|
||||
CHECK_OK(chat_format_grammar(declared, gq, &g, &why));
|
||||
CHECK_EQ(g.text, b->prompt().grammar);
|
||||
}
|
||||
|
||||
/* THE STRUCT GROWS AT ITS END. A plugin built against a header with fewer fields reports a smaller
|
||||
* struct_size, and the fields past it read as zero; one built against a larger header has its
|
||||
* extra fields ignored. Nothing is read past what the plugin said it has. */
|
||||
|
||||
Reference in new issue
Block a user