Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/antirez/ds4
/ functions
Functions
2,709 in github.com/antirez/ds4
⨍
Functions
2,709
◇
Types & classes
93
↓ 2 callers
Function
agent_kv_write_title_trailer
ds4_agent.c:3701
↓ 2 callers
Function
agent_line_for_offset
ds4_agent.c:5565
↓ 2 callers
Function
agent_maybe_save_before_exiting
Process exit is different from /new or /switch: once the terminal is already * restored, declining the save can terminate immediately and let the OS
ds4_agent.c:9594
↓ 2 callers
Function
agent_maybe_save_before_leaving_session
Ask before discarding a dirty user session. Fresh sessions that contain only * the system prompt are deliberately ignored. */
ds4_agent.c:9576
↓ 2 callers
Function
agent_mkdir_p
ds4_agent.c:3592
↓ 2 callers
Function
agent_prompt_queue_free
ds4_agent.c:8502
↓ 2 callers
Function
agent_prompt_queue_pop
ds4_agent.c:8452
↓ 2 callers
Function
agent_prompt_queue_push_front
ds4_agent.c:8460
↓ 2 callers
Function
agent_prompt_queue_take_all_echo
ds4_agent.c:8487
↓ 2 callers
Function
agent_prompt_yes_no_ex
Shared y/n prompt. By default it blocks forever like the historical helper; * callers that cannot safely stall the agent can request an automatic an
ds4_agent.c:9513
↓ 2 callers
Function
agent_publishf_system_status
ds4_agent.c:4013
↓ 2 callers
Function
agent_read_range
Read file text for the model. Normal mode shows plain line numbers. Raw * mode is reserved for cases where line decoration would corrupt the payloa
ds4_agent.c:5654
↓ 2 callers
Function
agent_session_title_from_span
ds4_agent.c:4423
↓ 2 callers
Function
agent_stream_feed_dsml_byte
ds4_agent.c:3185
↓ 2 callers
Function
agent_stream_normal_byte
Route ordinary assistant bytes either to normal markdown rendering or into * the DSML detector. The detector must hold short prefixes because the mo
ds4_agent.c:3338
↓ 2 callers
Function
agent_stream_tool_events
Mirror parser progress into the terminal visualizer. Parser state is the * source of truth; this function only decides what the user should see. */
ds4_agent.c:3141
↓ 2 callers
Function
agent_stream_wants_greedy_sampling
DSML structure is a machine-readable grammar, so once the model has clearly * started a tool stanza we decode grammar bytes greedily. Parameter valu
ds4_agent.c:7592
↓ 2 callers
Function
agent_syntax_separator
ds4_agent.c:2027
↓ 2 callers
Function
agent_tail_ends_with
ds4_agent.c:8636
↓ 2 callers
Function
agent_tool_calls_push
ds4_agent.c:1280
↓ 2 callers
Function
agent_tool_viz_code_byte
ds4_agent.c:2933
↓ 2 callers
Function
agent_tool_viz_code_prefix
ds4_agent.c:2888
↓ 2 callers
Function
agent_tool_viz_diff_prefix
ds4_agent.c:2874
↓ 2 callers
Function
agent_tool_viz_line_prefix
ds4_agent.c:2761
↓ 2 callers
Function
agent_tool_viz_render_read
ds4_agent.c:2827
↓ 2 callers
Function
agent_tool_viz_tool
ds4_agent.c:2779
↓ 2 callers
Function
agent_trace_escaped
ds4_agent.c:1168
↓ 2 callers
Function
agent_trace_token
ds4_agent.c:1185
↓ 2 callers
Function
agent_trace_tokens
ds4_agent.c:1201
↓ 2 callers
Function
agent_worker_build_system_tokens
ds4_agent.c:3991
↓ 2 callers
Function
agent_worker_compact_if_needed
ds4_agent.c:7517
↓ 2 callers
Function
agent_worker_has_user_session
ds4_agent.c:4324
↓ 2 callers
Function
agent_worker_init
Initialize the worker, cache directory, sysprompt checkpoint path, trace file, * and model thread. After this returns, all DS4 session mutation happ
ds4_agent.c:9421
↓ 2 callers
Function
agent_worker_needs_save
ds4_agent.c:4331
↓ 2 callers
Function
agent_worker_note_terminal_mode_may_have_changed
ds4_agent.c:6743
↓ 2 callers
Function
agent_worker_reset_to_sysprompt
Start a new session at the system/tool prompt. A fixed sysprompt.kv * checkpoint avoids paying this prefill cost repeatedly, but only when the * re
ds4_agent.c:4192
↓ 2 callers
Function
agent_worker_save_session_now
Save the current session under its stable agent identity. The worker owns * the live KV, so busy /save requests are deferred until a stable append-o
ds4_agent.c:4341
↓ 2 callers
Function
agent_worker_set_more
ds4_agent.c:5631
↓ 2 callers
Function
agent_worker_show_history
Render recent saved transcript text without mutating the live session. */
ds4_agent.c:4956
↓ 2 callers
Function
ansiEscapeLen
If s[] points at an ANSI CSI escape sequence (e.g. a color change like * ESC [ 1 ; 32 m), return its length in bytes. Otherwise return 0. * * The c
linenoise.c:425
↓ 2 callers
Function
anthropic_final_response
ds4_server.c:6905
↓ 2 callers
Function
anthropic_live_clear
ds4_server.c:8031
↓ 2 callers
Function
anthropic_msg_is_tool_result_tail
ds4_server.c:2553
↓ 2 callers
Function
anthropic_prepare_live_continuation
Prepare the Anthropic live-tool fast path. * * Anthropic's visible replay normally includes the assistant tool_use JSON and * the user tool_result.
ds4_server.c:2606
↓ 2 callers
Function
anthropic_sse_delta_live
ds4_server.c:7097
↓ 2 callers
Function
anthropic_stop_reason
ds4_server.c:6830
↓ 2 callers
Function
anthropic_tool_emit_string_value
ds4_server.c:7175
↓ 2 callers
Function
anthropic_tool_stream_free
ds4_server.c:7003
↓ 2 callers
Function
append_anthropic_block_content
ds4_server.c:1693
↓ 2 callers
Function
append_anthropic_content
ds4_server.c:6858
↓ 2 callers
Function
append_anthropic_usage_json
ds4_server.c:6891
↓ 2 callers
Function
append_cors_headers
ds4_server.c:4788
↓ 2 callers
Function
append_dsml_arg
ds4_server.c:2188
↓ 2 callers
Function
append_dsml_attr_escaped
ds4_server.c:2134
↓ 2 callers
Function
append_dsml_parameter_text
ds4_server.c:2144
↓ 2 callers
Function
append_openai_usage_json
ds4_server.c:4948
↓ 2 callers
Function
append_responses_usage_json
ds4_server.c:6448
↓ 2 callers
Function
append_tool_call_deltas_json
ds4_server.c:4766
↓ 2 callers
Function
append_tool_calls_json
ds4_server.c:4746
↓ 2 callers
Function
apply_anthropic_stream_tool_ids
ds4_server.c:8216
↓ 2 callers
Function
apply_openai_stream_tool_ids
ds4_server.c:8206
↓ 2 callers
Function
ascii_digit
ds4.c:22055
↓ 2 callers
Function
ascii_space
ds4.c:22059
↓ 2 callers
Function
assign_tool_call_ids
ds4_server.c:8193
↓ 2 callers
Function
buf_appendf
ds4_eval.c:1352
↓ 2 callers
Function
buf_reserve
ds4_server.c:114
↓ 2 callers
Function
build_invalid_dsml_tool_error_suffix
ds4_server.c:9520
↓ 2 callers
Function
build_question_prompt
ds4_eval.c:2363
↓ 2 callers
Function
build_toolless_thinking_visible_text
In thinking mode without tools, old assistant reasoning is intentionally not * rendered back into later prompts. The sampled live graph still contai
ds4_server.c:9780
↓ 2 callers
Function
bytes_has_prefix
ds4_cli.c:300
↓ 2 callers
Function
bytes_has_prefix
ds4_eval.c:2089
↓ 2 callers
Function
bytes_is_partial_prefix
ds4_cli.c:305
↓ 2 callers
Function
bytes_is_partial_prefix
ds4_eval.c:2094
↓ 2 callers
Function
c_string_value_at
Parse one or more adjacent C string literals. ``ds4_eval.c`` uses ordinary escaped C strings for embedded questions. We reuse those definiti
gguf-tools/imatrix/dataset/build_ds4_imatrix_dataset.py:849
↓ 2 callers
Function
chat_think_tool_recovery
Live recovery for a tool call started inside an unclosed <think> block. * * The model sometimes opens a DSML stanza without closing its thinking fir
ds4_server.c:9450
↓ 2 callers
Function
chunk_text
(text: str, size: int, overlap: int)
gguf-tools/imatrix/dataset/build_ds4_imatrix_dataset.py:271
↓ 2 callers
Function
cli_distributed_coordinator
ds4_cli.c:90
↓ 2 callers
Function
collect_tool_call_ids
ds4_server.c:8330
↓ 2 callers
Function
compressor_decode_one_decode_scratch
ds4.c:8762
↓ 2 callers
Function
compressor_finish_prefill_state_cpu
After prefill, clear unused compressor state rows so decode starts from the * same partial-window state the streaming path would have produced. */
ds4.c:8565
↓ 2 callers
Function
compressor_pool_decode_state
Pool the current compression window with a softmax over per-dimension scores. * Ratio-4 layers keep two lanes: attention compression and indexer comp
ds4.c:8610
↓ 2 callers
Function
continue_after_invalid_dsml
ds4_server.c:9575
↓ 2 callers
Function
cpu_decode_quantize_q8_0
Decode scratch owns this temporary activation quantization so generation * can assert that the hot path performs no malloc. */
ds4.c:5300
↓ 2 callers
Function
cursor_skip
ds4.c:1496
↓ 2 callers
Function
db_close
gguf-tools/deepseek4-quantize.c:558
↓ 2 callers
Function
db_find_shard
gguf-tools/deepseek4-quantize.c:450
↓ 2 callers
Function
db_tensor
gguf-tools/deepseek4-quantize.c:588
↓ 2 callers
Function
dist_activation_values_from_wire_bytes
ds4_distributed.c:804
↓ 2 callers
Function
dist_cli_parse_port
ds4_distributed.c:8092
↓ 2 callers
Function
dist_coordinator_build_route_plan
ds4_distributed.c:2201
↓ 2 callers
Function
dist_coordinator_can_pipeline_prefill
ds4_distributed.c:3421
↓ 2 callers
Function
dist_coordinator_prefill_chunk_cap
ds4_distributed.c:3441
↓ 2 callers
Function
dist_coordinator_prefill_prompt_pipelined
ds4_distributed.c:3513
↓ 2 callers
Function
dist_coordinator_send_remote_work_on_fd
ds4_distributed.c:2493
↓ 2 callers
Function
dist_decode_activation_payload
ds4_distributed.c:966
↓ 2 callers
Function
dist_kv_layer_tensor_bytes
ds4_distributed.c:4611
↓ 2 callers
Function
dist_kv_raw_live_valid
ds4_distributed.c:4671
↓ 2 callers
Function
dist_kv_route_shard
ds4_distributed.c:4860
↓ 2 callers
Function
dist_kv_route_shard_count
ds4_distributed.c:4856
↓ 2 callers
Function
dist_kv_route_validate
ds4_distributed.c:4878
← previous
next →
901–1,000 of 2,709, ranked by callers