MCPcopy Create free account

hub / github.com/PrismML-Eng/Bonsai-demo / functions

Functions83 in github.com/PrismML-Eng/Bonsai-demo

↓ 8 callersFunctionlog
(msg)
scripts/openwebui/seed_openwebui.py:99
↓ 8 callersMethodrequest
(self, method, path, payload=None, timeout=15)
scripts/openwebui/seed_openwebui.py:108
↓ 5 callersMethodread
(self, limit)
tests/test_tool_web_fetch.py:24
↓ 4 callersMethod_fetch_with_response
(self, response, chat_id="chat-1")
tests/test_tool_web_fetch.py:47
↓ 4 callersFunction_load_seed_module
()
tests/test_seed_openwebui.py:12
↓ 3 callersMethodquery_database
Run a read-only SQL query against the PrismML demo sales database using SQLite syntax. The database contains customers, products, ord
scripts/openwebui/tool_sql.py:39
↓ 2 callersMethod_break
(self)
scripts/openwebui/tool_web_fetch.py:75
↓ 2 callersFunction_normalize_text
(parts)
scripts/openwebui/tool_web_fetch.py:156
↓ 1 callersMethod__init__
(self, location)
scripts/openwebui/tool_web_fetch.py:206
↓ 1 callersFunction_attach_artifacts
Attach generated images using Native-compatible Open WebUI file events.
scripts/openwebui/tool_code_interpreter.py:85
↓ 1 callersFunction_check_url_public
Return an error string if the URL is unsafe to fetch, else None.
scripts/openwebui/tool_web_fetch.py:231
↓ 1 callersFunction_clean_stderr
Remove ANSI styling and harmless progress bars from Jupyter stderr.
scripts/openwebui/tool_code_interpreter.py:35
↓ 1 callersFunction_error_summary
(stderr: str)
scripts/openwebui/tool_code_interpreter.py:48
↓ 1 callersFunction_extract_artifact_markdown
Extract only uploaded image markdown produced by the builtin tool.
scripts/openwebui/tool_code_interpreter.py:80
↓ 1 callersFunction_extract_readable_html
(source: str)
scripts/openwebui/tool_web_fetch.py:163
↓ 1 callersFunction_finish_fetch
(chat_id: str, success: bool)
scripts/openwebui/tool_web_fetch.py:194
↓ 1 callersFunction_get
(url: str)
scripts/openwebui/tool_weather.py:11
↓ 1 callersFunction_has_execution_error
(stderr: str)
scripts/openwebui/tool_code_interpreter.py:56
↓ 1 callersFunction_is_public_ip
(ip_str: str)
scripts/openwebui/tool_web_fetch.py:218
↓ 1 callersFunction_model_params
Params for the seeded model record. The 27B (the launch model) uses the reference precise-task thinking-mode sampling. Older sizes (8B/4B/1.7B)
scripts/openwebui/seed_openwebui.py:199
↓ 1 callersFunction_normalize_execution
Distinguish clean success, useful partial output, and genuine failure.
scripts/openwebui/tool_code_interpreter.py:118
↓ 1 callersFunction_read_capped
Read the body, capping the decompressed size to guard against zip bombs.
scripts/openwebui/tool_web_fetch.py:257
↓ 1 callersFunction_reserve_fetch
Reserve a quota slot so parallel tool calls cannot exceed the cap.
scripts/openwebui/tool_web_fetch.py:183
↓ 1 callersFunction_suggested_fix
Return a targeted correction for common, confidently identified errors.
scripts/openwebui/tool_code_interpreter.py:67
↓ 1 callersFunction_truncate
(text: str, limit: int)
scripts/openwebui/tool_code_interpreter.py:28
↓ 1 callersFunction_without_leading_comments
Return SQL after whitespace and leading -- / /* */ comments.
scripts/openwebui/tool_sql.py:15
↓ 1 callersFunctioncleanup_stale
Delete records this script created in past runs for models that no backend currently serves. Never touches records made by hand.
scripts/openwebui/seed_openwebui.py:323
↓ 1 callersFunctiondisplay_name
Friendly UI name: strip paths and .gguf, tag the backend.
scripts/openwebui/seed_openwebui.py:191
↓ 1 callersFunctionfetch_backend_model_ids
Ask an OpenAI-compatible backend which model ids it serves. Returns (bonsai_ids, other_ids) - some backends (mlx-vlm) also list helper models
scripts/openwebui/seed_openwebui.py:143
↓ 1 callersMethodfetch_url
Fetch a web page and return its readable text content. Use this to open links the user provides or URLs found via web search.
scripts/openwebui/tool_web_fetch.py:279
↓ 1 callersMethodget_content_charset
(self)
tests/test_tool_web_fetch.py:15
↓ 1 callersMethodhandle_endtag
(self, tag)
scripts/openwebui/tool_web_fetch.py:112
↓ 1 callersMethodhandle_starttag
(self, tag, attrs)
scripts/openwebui/tool_web_fetch.py:80
↓ 1 callersFunctionhide_model
Soft-disable a helper model so it doesn't clutter the picker.
scripts/openwebui/seed_openwebui.py:302
↓ 1 callersFunctionmain
()
scripts/mlx_generate.py:50
↓ 1 callersFunctionmain
()
scripts/openwebui/seed_openwebui.py:345
↓ 1 callersMethodopen
(self, request, timeout)
tests/test_tool_web_fetch.py:38
↓ 1 callersFunctionprice
(pid, day)
scripts/openwebui/make_demo_db.py:84
↓ 1 callersFunctionseed_model
(api, model_id, vision, native_tools, backend)
scripts/openwebui/seed_openwebui.py:210
↓ 1 callersFunctionseed_stream_filter
Install the global stream filter that works around an Open WebUI bug: mlx_vlm.server sends "timings": null in every SSE chunk and Open WebUI's
scripts/openwebui/seed_openwebui.py:263
↓ 1 callersFunctionseed_tool
(api, tool_id, name, filename, description)
scripts/openwebui/seed_openwebui.py:159
↓ 1 callersMethodsignin
With WEBUI_AUTH=false the frontend signs in with empty credentials and receives the auto-admin's session token; do the same.
scripts/openwebui/seed_openwebui.py:121
↓ 1 callersFunctionwait_for_webui
(api, tries=60)
scripts/openwebui/seed_openwebui.py:133
Method__enter__
(self)
tests/test_tool_web_fetch.py:27
Method__exit__
(self, exc_type, exc, tb)
tests/test_tool_web_fetch.py:30
Method__init__
(self, base)
scripts/openwebui/seed_openwebui.py:104
Method__init__
(self)
scripts/openwebui/tool_web_fetch.py:59
Method__init__
(self, body, content_type="text/html; charset=utf-8")
tests/test_tool_web_fetch.py:20
Method__init__
(self, response)
tests/test_tool_web_fetch.py:35
Method__init__
(self)
tests/test_seed_openwebui.py:21
Methodemitter
(event)
tests/test_tool_code_interpreter.py:66
Methodexecute_code
Execute Python in a fresh Jupyter kernel. Make each call self-contained. Open WebUI attaches displayed plots and generated images to
scripts/openwebui/tool_code_interpreter.py:150
Methodget_weather
Get current weather and a daily forecast for a city or place name. :param location: City or place name, e.g. "Lisbon" or "Maui, Hawa
scripts/openwebui/tool_weather.py:18
Methodhandle_data
(self, data)
scripts/openwebui/tool_web_fetch.py:135
Methodhandle_startendtag
(self, tag, attrs)
scripts/openwebui/tool_web_fetch.py:131
Methodredirect_request
(self, req, fp, code, msg, headers, newurl)
scripts/openwebui/tool_web_fetch.py:214
Methodrequest
(self, method, path, payload=None, timeout=15)
tests/test_seed_openwebui.py:24
MethodsetUp
(self)
tests/test_tool_sql.py:29
MethodsetUp
(self)
tests/test_tool_web_fetch.py:43
Methodstream
(self, event: dict)
scripts/openwebui/filter_mlx_stream.py:9
MethodtearDown
(self)
tests/test_tool_sql.py:39
Methodtest_27b_uses_precise_thinking_sampling
(self)
tests/test_seed_openwebui.py:79
Methodtest_binary_content_is_rejected_without_consuming_quota
(self)
tests/test_tool_web_fetch.py:125
Methodtest_description_names_dialect_and_common_date_trap
(self)
tests/test_tool_sql.py:17
Methodtest_generated_image_has_model_fallback_without_event_emitter
(self)
tests/test_tool_code_interpreter.py:85
Methodtest_generated_image_is_attached_with_native_compatible_file_event
(self)
tests/test_tool_code_interpreter.py:63
Methodtest_large_detailed_results_are_withheld
(self)
tests/test_tool_sql.py:52
Methodtest_leading_line_and_block_comments_are_allowed
(self)
tests/test_tool_sql.py:43
Methodtest_model_disables_openwebui_citation_rewrite
(self)
tests/test_seed_openwebui.py:30
Methodtest_navigation_only_page_is_rejected_and_does_not_consume_quota
(self)
tests/test_tool_web_fetch.py:94
Methodtest_non_image_result_is_preserved
(self)
tests/test_tool_code_interpreter.py:99
Methodtest_nonfatal_warning_is_preserved_without_marking_failure
(self)
tests/test_tool_code_interpreter.py:115
Methodtest_prefers_article_and_returns_source_metadata
(self)
tests/test_tool_web_fetch.py:60
Methodtest_progress_only_stderr_is_clean_success
(self)
tests/test_tool_code_interpreter.py:15
Methodtest_prompt_is_generic_bounded_and_date_aware
(self)
tests/test_seed_openwebui.py:49
Methodtest_quota_reservations_include_parallel_inflight_calls
(self)
tests/test_tool_web_fetch.py:116
Methodtest_repo_owned_code_tool_is_attached_when_jupyter_is_on
(self)
tests/test_seed_openwebui.py:72
Methodtest_small_results_include_completeness_marker
(self)
tests/test_tool_sql.py:61
Methodtest_tool_description_is_generic_and_allows_api_discovery
(self)
tests/test_tool_code_interpreter.py:53
Methodtest_traceback_with_image_is_partial_success
(self)
tests/test_tool_code_interpreter.py:42
Methodtest_traceback_without_result_is_compact_error
(self)
tests/test_tool_code_interpreter.py:24
Methodtest_unreadable_page_releases_slot_for_a_retry
(self)
tests/test_tool_web_fetch.py:106
Methodtest_unrelated_error_does_not_receive_yfinance_advice
(self)
tests/test_tool_code_interpreter.py:105