MCPcopy Create free account

hub / github.com/NVIDIA-NeMo/Switchyard / functions

Functions4,886 in github.com/NVIDIA-NeMo/Switchyard

↓ 242 callersMethodmap
(slf: PyRef<'_, Self>, callback: &Bound<'_, PyAny>)
crates/switchyard-py/src/interop/response.rs:230
↓ 149 callersMethoditer
Iterate the evicted target ids in arbitrary order.
crates/switchyard-components/src/contracts/context.rs:213
↓ 137 callersMethodappend
( &mut self, context: RoutingLogContext, model: &str, tier: Option<&str>,
crates/switchyard-server/src/routing_log.rs:44
↓ 110 callersMethodget
Gets an immutable typed extension by Rust type.
crates/switchyard-components/src/contracts/context.rs:73
↓ 101 callersMethodget
(self, key: str)
tests/test_session_affinity.py:34
↓ 101 callersMethodinsert
Inserts a typed extension, returning the previous value of the same type.
crates/switchyard-components/src/contracts/context.rs:65
↓ 85 callersMethodis_empty
Returns whether the extension map is empty.
crates/switchyard-components/src/contracts/context.rs:176
↓ 84 callersMethodpush
Appends one observation.
crates/switchyard-components/tests/adversarial_multi_llm_backend.rs:48
↓ 82 callersMethodrequest_to
Return *request* in the target wire format.
switchyard_rust/translation.py:114
↓ 80 callersMethodanthropic
Build an Anthropic Messages request.
switchyard_rust/core.py:79
↓ 79 callersMethodget
Return the builder method for *preset_id*. Raises: ValueError: If *preset_id* is not in :attr:`PRESETS`. The err
switchyard/lib/profiles/random_routing_presets.py:130
↓ 69 callersMethodlock
Locks the context unless an async Rust component currently owns it.
crates/switchyard-py/src/interop/context.rs:29
↓ 65 callersMethodopenai_chat
Build an OpenAI Chat Completions request.
switchyard_rust/core.py:69
↓ 60 callersMethodget
Return a cached value and mark it as most recently used.
switchyard/lib/session_cache.py:29
↓ 59 callersFunctionbuild_route_bundle_table
Parse *raw* dict and build a :class:`RouteTable`. Thin entrypoint that the YAML loader and any other dict-driven caller uses. Parses + env-ex
switchyard/cli/route_bundle.py:360
↓ 54 callersMethodopenai_completion
Build a buffered OpenAI Chat Completions response.
switchyard_rust/core.py:190
↓ 51 callersMethodjson
Creates a one-shot server returning JSON.
crates/switchyard-components/tests/support/mod.rs:63
↓ 48 callersMethoditems
Iterate ``(model_id, chain, metadata)`` triples in registration order. Used when a caller needs to merge one table into another — e.g. a
switchyard/lib/route_table.py:103
↓ 46 callersMethodrun
Process a request to completion, returning the final [`Response`] and the trace of [`Decision`]s the algorithm made along the way.
crates/libsy/src/core/algorithm.rs:710
↓ 45 callersMethodtranslate_request
Translates a request body from source format to target format.
crates/switchyard-translation/src/engine.rs:148
↓ 43 callersMethodresolve
Return the concrete backend format for ``tier``. Explicit formats are already resolved. ``AUTO`` needs a real endpoint probe, so miss
switchyard/lib/backends/backend_format_resolver.py:53
↓ 42 callersMethodas_str
Returns the stable lowercase tier label.
crates/switchyard-components/src/request_processors/random_routing.rs:26
↓ 41 callersMethoditer_components
(self)
tests/test_subagent_routing.py:33
↓ 40 callersMethodopenai_responses
Build an OpenAI Responses request.
switchyard_rust/core.py:74
↓ 40 callersMethodprocess
(self, ctx, request)
tests/test_infra.py:51
↓ 37 callersMethodinfo
Push a fire-and-forget [`DriverStep::Info`] payload; there is no promise to await for a response. Awaits channel capacity (the consumer pacing the str
crates/libsy/src/core/driver.rs:195
↓ 37 callersMethodlen
Returns the number of stored extension values.
crates/switchyard-components/src/contracts/context.rs:171
↓ 36 callersMethodopenai_stream
Build a streaming OpenAI Chat Completions response.
switchyard_rust/core.py:195
↓ 36 callersMethodsnapshot
Returns a computed snapshot suitable for JSON serialization.
crates/switchyard-components/src/stats/accumulator.rs:306
↓ 33 callersFunctionopenai_chat
(body: Value)
crates/switchyard-components/src/dimension_collector/response/checks.rs:225
↓ 33 callersMethodpush
Apply one chunk. Later `MessageStart`/`Usage`/`MessageStop` fields overwrite earlier ones; text, reasoning, and tool-call arguments append.
crates/protocol/src/stream.rs:346
↓ 30 callersMethodget
The prompt configured for `target`, if any.
crates/libsy/src/algorithms/util/prompts.rs:88
↓ 29 callersFunctionresponse_type_matches
Return whether a Rust-backed response has the requested wire shape.
switchyard_rust/core.py:691
↓ 29 callersFunctiontarget_backend
Builds a target/backend pair for `MultiLlmBackend`.
crates/switchyard-components/tests/adversarial_multi_llm_backend.rs:175
↓ 28 callersFunctionbuild_switchyard_app
Create a FastAPI app serving *switchyard* over all inbound formats. Registers three LLM endpoints plus a liveness probe: - ``POST /v1/chat/c
switchyard/server/switchyard_app.py:67
↓ 28 callersMethodmodel_dump
(self, **kwargs: object)
tests/test_switchyard_rust_core_bindings.py:157
↓ 28 callersMethodwith_classifier
Appends a classifier to the cascade.
crates/libsy/src/algorithms/fall_through.rs:191
↓ 27 callersMethodcall
(&self, ctx: &mut ProxyContext, request: &ChatRequest)
crates/switchyard-components/tests/stats_processors.rs:94
↓ 27 callersMethodcontains
Returns whether a value of type `T` is present.
crates/switchyard-components/src/contracts/context.rs:163
↓ 27 callersFunctionrequest_type_matches
Return whether a request has the requested wire format.
switchyard_rust/core.py:645
↓ 26 callersMethodlock
(&self)
crates/switchyard-server/src/stats/accumulator.rs:169
↓ 25 callersFunction_responses_request_to_chat
(body: object)
tests/test_responses_openai_translation.py:15
↓ 25 callersMethodbuild
(self)
tests/test_python_profile_abstractions.py:408
↓ 25 callersFunctionsend
(app: &Router, method: &str, path: &str, body: Option<Value>)
crates/switchyard-server/tests/server.rs:570
↓ 24 callersFunction_run_baseline
( tmp_path: Path, *args: str, env: dict[str, str] | None = None, include_dataset: bool = True,
tests/test_run_baseline_script.py:148
↓ 23 callersMethodbuild
(&self)
crates/switchyard-server/src/config.rs:60
↓ 23 callersMethodfrom_config
Builds a contract from user settings and packaged defaults. The response format must contain `json_schema.schema` and is retained separately for the
crates/libsy/src/algorithms/util/classifier_contract.rs:47
↓ 22 callersFunction_config
( *, profile_name: str = "coding_agent", enable_stats: bool = True, classifier_min_confidence:
tests/test_deterministic_routing_profile.py:52
↓ 22 callersFunction_request
(content: str = "hello", *, prior_assistant_turns: int = 0)
tests/test_signal_tier_selector_request_processor.py:65
↓ 22 callersMethodprocess
(self, ctx: ProxyContext, request: ChatRequest)
switchyard/lib/processors/llm_classifier/tier_selector_request_processor.py:202
↓ 22 callersMethodregister
Register *switchyard* as the exact-match chain for *model*.
switchyard/lib/route_table.py:73
↓ 21 callersMethodcall
(&self, ctx: &mut ProxyContext, request: &ChatRequest)
crates/switchyard-components/tests/adversarial_multi_llm_backend.rs:132
↓ 21 callersMethodcaptured
Waits for and returns the captured request.
crates/switchyard-components/tests/support/mod.rs:79
↓ 21 callersMethodrecord_success
Records one successful routed backend call.
crates/switchyard-server/src/stats/accumulator.rs:36
↓ 21 callersMethodsnapshot
Returns a serializable point-in-time snapshot.
crates/switchyard-server/src/stats/accumulator.rs:159
↓ 21 callersMethodwarning
Creates a warning diagnostic.
crates/switchyard-translation/src/diagnostic.rs:31
↓ 20 callersMethodcall_rewrite_model
Calls the backend for `model_name` (or the request's own model), over the wire format the request pins in its metadata (else the model's default backe
crates/libsy-llm-client/src/client.rs:363
↓ 19 callersMethodis_empty
Whether any target has a prompt, so a caller can skip wiring the processor when none does.
crates/libsy/src/algorithms/util/prompts.rs:94
↓ 19 callersMethodlookup_switchyard
Return the chain for *model*. Records *model* as the last successfully resolved id (see :attr:`last_looked_up`). Raises:
switchyard/lib/route_table.py:113
↓ 19 callersFunctionrequest_for
(model: Option<&str>, stream: bool)
crates/libsy-llm-client/src/client.rs:925
↓ 19 callersMethodvalues
Returns a cloned copy of all observations.
crates/switchyard-components/tests/adversarial_multi_llm_backend.rs:54
↓ 18 callersMethod_make_chain
(self, **overrides)
tests/test_switchyard.py:298
↓ 18 callersFunctionanthropic
(body: Value)
crates/switchyard-components/src/dimension_collector/response/checks.rs:229
↓ 18 callersMethodbody
Returns the wrapped JSON request body.
crates/switchyard-components/src/contracts/types.rs:39
↓ 18 callersMethodcall
(self, ctx: ProxyContext, request: ChatRequest)
tests/test_switchyard.py:191
↓ 18 callersMethodget
(&self, key: &str)
crates/switchyard-server/src/observability.rs:66
↓ 18 callersMethodprocess
(self, ctx: ProxyContext, request: ChatRequest)
switchyard/lib/processors/llm_classifier/request_processor.py:342
↓ 18 callersMethodrecord
Remembers that `target` overflowed for `identity`, tracking at most [`MAX_EVICTION_IDENTITIES`] identities.
crates/libsy/src/core/algorithm.rs:485
↓ 18 callersMethodrecord_usage
Records usage and terminal latency after a successful routed call.
crates/switchyard-server/src/stats/accumulator.rs:84
↓ 18 callersMethodremove
Removes a typed extension and returns it when present.
crates/switchyard-components/src/contracts/context.rs:89
↓ 18 callersMethodtap
(_event)
tests/test_switchyard.py:129
↓ 18 callersFunctiontext_request
Builds a single-turn request: one user message carrying `prompt`, for `model`. This deliberately creates only the common text shape. Construct [`LlmR
crates/protocol/src/lib.rs:25
↓ 18 callersMethodtranslate_event
Translates one streaming source event into zero or more target events.
crates/switchyard-translation/src/engine.rs:229
↓ 18 callersMethodtranslate_response
Translates a response body from source format to target format.
crates/switchyard-translation/src/engine.rs:205
↓ 17 callersFunction_deterministic_routing_switchyard
Build the profile-backed runtime used by these tests.
tests/test_deterministic_routing_profile.py:98
↓ 17 callersMethodaclose
Retain asynchronous lifecycle compatibility without owning a transport.
examples/experimental/litellm/src/switchyard_litellm/client.py:343
↓ 17 callersMethodanthropic_completion
Build a buffered Anthropic response.
switchyard_rust/core.py:210
↓ 17 callersFunctionmake_request
(*, model: str = "gpt-4o")
tests/test_switchyard.py:52
↓ 17 callersMethodprocess
Records request-start metadata and returns the request unchanged.
crates/switchyard-components/src/request_processors/stats.rs:27
↓ 17 callersMethodrun
(self, input: ProfileInput)
tests/test_python_profile_abstractions.py:59
↓ 17 callersFunctionwith_messages
(messages: Vec<Message>)
crates/libsy/src/algorithms/util/tool_signals.rs:608
↓ 17 callersMethodwith_runtime_components
Return a copy with serving-level stats and processor hooks applied. Profile configs stay user-facing and parseable; shared serving resources
switchyard/lib/profiles/chain.py:106
↓ 16 callersFunction_line_argv
(stdout: str, prefix: str)
tests/test_run_baseline_script.py:196
↓ 16 callersFunction_write_server_config
(path: Path)
tests/test_run_baseline_script.py:209
↓ 16 callersFunctionfake_stream
(chunks: list[ChatCompletionChunk])
tests/test_chat_response.py:67
↓ 16 callersMethodinto_agg
Reduce to the buffered aggregate: return an `Agg` unchanged, or drive a `Stream` to completion, folding its normalized chunks into an [`AggLlmResponse
crates/protocol/src/stream.rs:142
↓ 16 callersMethodlock
(&self)
crates/switchyard-components/src/stats/accumulator.rs:318
↓ 16 callersFunctionrequest
()
crates/libsy/src/core/algorithm.rs:981
↓ 16 callersMethodstream
Take the single consumer stream of [`DriverStep`]s. Callable once: a second call yields a one-item stream carrying an `Err`, since the receiver is gon
crates/libsy/src/core/driver.rs:241
↓ 16 callersFunctiontarget
Builds a target with explicit endpoint credentials for native backend tests.
crates/switchyard-components/tests/adversarial_native_backends.rs:67
↓ 15 callersFunction_config
(**overrides: Any)
tests/test_escalation_router_profile.py:43
↓ 15 callersFunction_load_native
()
switchyard_rust/core.py:374
↓ 15 callersFunction_request
(**body_overrides: Any)
tests/test_llm_classifier_request_processor.py:77
↓ 15 callersFunction_request
Chat request with enough prior assistant turns to pass the judge gate.
tests/test_escalation_judge_request_processor.py:56
↓ 15 callersFunction_verdict_json
(escalate: bool, reason: str = "same error repeating")
tests/test_escalation_judge_request_processor.py:52
↓ 15 callersMethodas_str
Stable lowercase label used in stats.
crates/libsy/src/algorithms/util/stage.rs:164
↓ 15 callersMethodbind
Binds the configured address and prepares the HTTP router.
crates/switchyard-server/src/lib.rs:288
↓ 15 callersFunctionchat_map
A one-model config list: "gpt" served over OpenAI Chat at base_url.
crates/libsy-llm-client/src/client.rs:837
↓ 15 callersFunctionget_tool_result_signal
(ctx: &Bound<'_, PyAny>)
crates/switchyard-py/src/component_bindings/dimension_collector.rs:384
↓ 15 callersFunctionmodel_stats
Fetches one model stats block with an explicit test error on absence.
crates/switchyard-components/tests/stats_processors.rs:830
next →1–100 of 4,886, ranked by callers