Commit graph

494 commits

Author SHA1 Message Date
Abhishek
0716582aa7
feat: add devcontainer based setup (#352)
* feat: add devcontainer for local setup

* feat: add local install hook

* feat: add devcontainer based setup docs

* feat: use uv in api/Dockerfile

* fix: fix CI scripts

* fix: fix post job cleanup step
2026-05-25 20:44:22 +05:30
Abhishek Kumar
285de92528 fix: fix vobiz webhook signature validation 2026-05-25 18:30:06 +05:30
Sabiha Khan
a725fda274 docs: fix asterisk protocol in mintlify websocket client config 2026-05-25 10:27:03 +05:30
Abhishek Kumar
bbb4f91a27 fix: fix projection to TS when fetching agnet in MCP 2026-05-23 14:45:50 +05:30
Abhishek
3892b58486
feat: add ultravox realtime and fix signature issue in telephony (#345)
* feat: add ultravox realtime and fix signature issue in telephony

- Add UltraVox realtime
- Fix signature issue on telephony

* fix: fix regression for wss_backend_endpoint
2026-05-23 12:51:55 +05:30
Abhishek Kumar
9135c2da13 feat: add xai grok as realtime model 2026-05-22 18:04:59 +05:30
Abhishek Kumar
291264de7b Merge branch 'main' of https://github.com/dograh-hq/dograh 2026-05-22 14:36:54 +05:30
Abhishek Kumar
ad2fa07058 feat: add google stt and tts. add folders to organize agents 2026-05-22 14:36:50 +05:30
Octopus
0e0d3136ca
feat: add MiniMax provider support (Chat + TTS) (#309)
* feat: add MiniMax provider support (Chat + TTS)

- Add MiniMax LLM provider using OpenAI-compatible API
  - Models: MiniMax-M2.7, MiniMax-M2.7-highspeed
  - Default base URL: https://api.minimax.io/v1
  - Uses MINIMAX_API_KEY for authentication
- Add MiniMax TTS provider using Pipecat's MiniMaxHttpTTSService
  - Models: speech-2.8-hd (default), speech-2.8-turbo
  - 6 built-in voices
  - Requires group_id configuration
- Add unit tests for both providers

* fix(minimax): validator, temperature, session cleanup, reasoning filter
  - check_validity.py: wire MiniMax into _validator_map and enforce
    group_id at save time. Without this, saving a config with a valid
    key was rejected.
  - registry.py: surface temperature on the LLM config (gt=0; MiniMax
    rejects 0) and base_url on the TTS config
  - service_factory.py:
    * Plumb temperature through create_llm_service
    * Normalize TTS base_url to include /t2a_v2 — pipecat appends only
      ?GroupId=... to the URL.
    * Use the new MiniMaxLLMService (from pipecat) to strip
      <think>...</think> reasoning that MiniMax-M2.7 emits inline in
      delta.content (otherwise it leaks straight to TTS).
    * Use MiniMaxOwnedSessionTTSService so the per-instance aiohttp
      session gets closed in cleanup() instead of leaking sockets/FDs.
  - minimax_tts.py: small wrapper around MiniMaxHttpTTSService that owns
    the session it was handed (pipecat's caller-owns-session API
    conflicts with the ftory's per-instance pattern).
  - pipecat submodule: bumps to a commit that adds MiniMaxLLMService — a
    thin OpenAILLMService subclass with the streaming <think> filter
    (mirrors NvidiaLLMService's pattern for NIM reasoning models).
  - Tests updated/added for all of the above.

  Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: octo-patch <octo-patch@github.com>
Co-authored-by: Sabiha Khan <sabihak89@gmail.com>
2026-05-22 13:09:41 +05:30
mohamedsalem-bot
38c2003734
chore: adding tuner docs (#341) 2026-05-22 11:55:11 +05:30
Sabiha Khan
21951eca18
chore(main): release dograh 1.31.0 (#318) 2026-05-21 17:29:59 +05:30
Abhishek Kumar
3da439207c chore: minor UI fixes 2026-05-21 17:20:21 +05:30
@aaronjmars
332754a809
fix(security): bump python-multipart 0.0.20 -> 0.0.27 (#332)
Closes three known advisories in python-multipart, all reachable
from the FastAPI multipart form-parser used across the API
(transcribe_audio, knowledge_base uploads, presigned upload flows):

- GHSA-wp53-j4wj-2cfg (HIGH, CWE-22) — arbitrary file write via
  non-default configuration. Fixed in 0.0.22.
- GHSA-pp6c-gr5w-3c5g (HIGH, CWE-400) — DoS via unbounded multipart
  part headers. Fixed in 0.0.27.
- GHSA-mj87-hwqh-73pj (MOD, CWE-400) — DoS via large multipart
  preamble or epilogue. Fixed in 0.0.26.

0.0.27 is a patch-level bump within the same 0.0.x line, no API
changes; fastapi==0.135.3 only requires python-multipart>=0.0.7 so
the upper bound is unaffected.

Detected by Aeon + osv-scanner.

Co-authored-by: aeonframework <aeon@aaronjmars.com>
2026-05-21 15:29:27 +05:30
Abhishek
d97d1d72cd
feat: add chat based testing for voice agent (#308)
* feat: add backend foundations

* feat: add text chat UI

* chore: simplify the reload behaviour

* fix: fix upgrade banner to be triggered after package upload

* feat: simplify TesterPanel design

* chore: fix formatting and generate client

* chore: fix tracing for text chat mode

* fix: fix revert and edit CTA

* refactor: refactor TesterPanel into smaller components

* feat: enable runtime transition of nodes

* fix: fix review comments
2026-05-21 15:20:02 +05:30
Mohamed-Mamdouh
67479e98fd
fix timestamps in tuner accumelator (#335)
* fix timestamps in tuner accumelator

* chore: refactor strip_thought_ids_from_messages

---------

Co-authored-by: Abhishek Kumar <abhishek@a6k.me>
2026-05-21 07:43:50 +05:30
deepashreekedia
af66372b65
fix(webRTC): LAN IP filtering (#333)
* fix webRTC voice call for LAN setup

* log re-add

* refactor: extract ICE candidate filtering policy

* fix: decouple relay-only diagnostics from LAN TURN setup

* fix: fix remote_up script

---------

Co-authored-by: deepashreeKedia <kediadeepashree2@gmail.com>
Co-authored-by: Abhishek Kumar <abhishek@a6k.me>
2026-05-21 07:28:43 +05:30
Abhishek Kumar
8484e4bfaf test(mcp): guard instructions.py against tool drift
The MCP `instructions` hint is static and baked into the client prompt,
while tool names, signatures, and error codes are discovered dynamically
via tools/list. The two had drifted: instructions restated stale
signatures and an error-code enum that omitted schema_validation and
trigger_path_conflict.

- Trim instructions.py to tool names + call order; stop restating
  signatures and error codes the dynamic surface already carries.
- Document each tool's full error_code contract in the save_workflow and
  create_workflow docstrings (the descriptions shipped via tools/list).
- Add test_mcp_instructions_drift.py: every tool named in the guide must
  be registered, and every error_code a tool returns must appear in its
  description.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-20 18:44:18 +05:30
Leoy
5762095edf
feat(mcp): add search_docs tool over docs corpus (closes #295) (#316)
* feat(mcp): add search_docs tool over Mintlify docs corpus

Closes #295. The docs at https://docs.dograh.com promise "Search the
Dograh docs for how to configure a TURN server" as an MCP example
prompt, but no search_docs tool exists in the MCP server — agents can
list workspace resources but cannot search the documentation.

This adds a dependency-free, in-process keyword search over the
`docs/` tree shipped into the API image (`COPY ./docs ./docs`):

- New `api/mcp_server/tools/docs_search.py` — async `search_docs(query,
  limit=10)` with weighted scoring (path > title > body), a 25-result
  hard cap, snippet extraction around the first term hit, and graceful
  empty-list degradation when docs aren't on disk. `DOGRAH_DOCS_PATH`
  env var overrides location discovery for non-Docker layouts.

- Registered in `api/mcp_server/server.py` alongside the other tools,
  keeping the existing list-alphabetical convention.

- `api/tests/test_mcp_docs_search.py` — 18 unit tests covering the
  pure helpers (tokenizer, frontmatter stripping, title extraction,
  scoring weights, URL building) and end-to-end ranking, limit
  clamping, empty-corpus degradation, and input-validation errors.
  Mocks `authenticate_mcp_request` to avoid the DB dependency,
  mirroring `test_mcp_save_workflow.py`.

Implementation notes:
- The docs corpus is ~100 files / ~140k LoC, so a per-call scan runs
  well under 50 ms; avoiding a vector index / embedding backend keeps
  the tool zero-dependency and works for fully offline self-hosted
  deployments.
- Authentication is required for consistency with the other MCP tools
  (and to route through the existing rate-limit middleware), even
  though docs are not org-scoped data.
- Title/path matches deliberately outweigh body matches so a page
  whose subject IS the query term outranks one that merely mentions
  it incidentally.

* feat: improve docs search

---------

Co-authored-by: Abhishek Kumar <abhishek@a6k.me>
2026-05-20 18:20:35 +05:30
Abhishek Kumar
d93d7aff4d feat: add Review AGENTS.md Skill 2026-05-20 16:20:07 +05:30
Abhishek Kumar
ee216c0e40 chore: refactor AGENTS.md 2026-05-20 15:56:52 +05:30
Mohamed-Mamdouh
5f28c1b2a9
feat: add Tuner Integration to Dograh (#311)
* Add tuner integration

* bump pipecat version

* chore: update pipecat submodule to match upstream and use tuner-pipecat-sdk 0.2.0

Update pipecat submodule from 0.0.109.dev23 to 13e98d0d9 (the exact commit
upstream dograh-hq/dograh uses after v1.30.1). This installs pipecat-ai as
1.1.0.post277 via setuptools_scm, satisfying tuner-pipecat-sdk 0.2.0's
pipecat-ai>=1.0.0 requirement.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* wire tuner

* feat: refactor integrations into self contained packages

* chore: simplify ensure_public_access_token

* fix: remove NodeSpec and make DTOs the source of truth

* feat: send relevant signal to mcp using to_mcp_dict

* fix: fix tests

* cleanup: remove nango integrations

* feat: add agents.md for integrations

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-authored-by: Abhishek Kumar <abhishek@a6k.me>
2026-05-20 14:37:33 +05:30
palinko91
afa78fe859
fix(stt): align Speechmatics language registry with official transcription codes (#317) 2026-05-19 19:00:38 +05:30
Abhishek
151bf77e40
feat: add agent skills to review PR (#320) 2026-05-19 17:02:26 +05:30
Sabiha Khan
8778bb453e
chore: mandate telnyx signature verification (#319) 2026-05-19 16:50:27 +05:30
HaiTao Wu
5b1e3980b1
docs: add Simplified Chinese translation of README (#305)
* docs: add Simplified Chinese translation of README

* docs(zh-CN): add community-maintained notice per reviewer feedback
2026-05-19 16:10:38 +05:30
Paulo Busato Favarato
75839f9de5
feat(mcp): generic MCP tool source with per-node function filtering (#301)
* feat(mcp): generic MCP tool source with per-node function filtering

Adds a Model Context Protocol tool category: connect a customer MCP
server and expose its tools to the agent, with optional per-node
allow-listing of individual MCP functions.

- ToolCategory.MCP enum + alembic migration
- MCP definition validator and collision-safe function-name namespacing
- McpToolSession wrapper: graceful-degrade, per-call open/close lifecycle
- CustomToolManager MCP branch (schemas + proxy handlers)
- Per-node mcp_tool_filters threaded through DTO/graph/engine
- Best-effort discovered_tools catalog cache + POST /tools/{uuid}/mcp/refresh
- UI: MCP create/edit config, tabbed ToolSelector with per-node toggles

* feat: refactor for code standardisation and documentation

---------

Co-authored-by: Abhishek Kumar <abhishek@a6k.me>
2026-05-19 16:10:00 +05:30
Sabiha Khan
0097974444
chore(main): release dograh 1.30.1 (#304) 2026-05-17 20:48:55 +05:30
Abhishek Kumar
ba7d45fde0 fix: fix race between context init and keepalive for Dograh TTS 2026-05-17 20:45:47 +05:30
Sabiha Khan
ae3eed1854
chore(main): release dograh 1.30.0 (#287) 2026-05-16 20:10:36 +05:30
Abhishek Kumar
fc04f31639 fix: force FORCE_TURN_RELAY for local IPs in setup 2026-05-16 18:37:38 +05:30
Abhishek
2381a803ad
feat: add openai realtime models (#298)
* feat: add openai realtime models

* chore: bump pipecat

* fix: resample telephony audio for openai realtime

* fix: sampling rate fix for openai realtime

* chore: clean up dead code
2026-05-16 18:05:23 +05:30
Abhishek
45b00cd5d0
chore: remove looptalk (#299)
* chore: remove looptalk

Remove looptalk in the current version. We will be rethinking looptalk in a fresh way.

* chore: formatting fix
2026-05-16 17:45:12 +05:30
Sabiha Khan
0523dcb079 fix: provider resolution in telephony cost calculation post workflow integration calls 2026-05-16 13:19:26 +05:30
Sabiha Khan
53f1959edf
chore: override stack provider ui literals to contain Google Business instead of Google (#294) 2026-05-15 16:46:07 +05:30
Gianfranco P
a82c9fdbc1
Update Vobiz account link from vobiz.com to vobiz.ai (#292) 2026-05-15 13:54:44 +05:30
Sabiha Khan
ea13492a89 docs: update README.md 2026-05-14 23:48:32 +05:30
Nir Simionovich
7df73beea3
Resolve an issue with direct socket connections using the wrong event… (#289)
* Resolve an issue with direct socket connections using the wrong event data.

* Resolve the formatting issus in the provider file

* chore: fix import ordering with ruff

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Nir Simionovich <nirs@cloudonix.io>
Co-authored-by: Abhishek Kumar <abhishek@a6k.me>
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-14 18:20:14 +05:30
Abhishek Kumar
5a59936b16 chore: fix AGENTS.md 2026-05-14 15:02:57 +05:30
Abhishek Kumar
46e66a0672 Merge branch 'main' of https://github.com/dograh-hq/dograh 2026-05-14 15:02:18 +05:30
Abhishek Kumar
ae2efefa59 chore: add powershell version for setup_local 2026-05-14 15:01:11 +05:30
Abhishek
87699f2dee
chore: refactor setup scrpts (#288)
* refactor setup scrpts

* update docker compose to use dograh-init

* avoid creating unnecessary conf files

* fix local setup script

* add agents.md
2026-05-14 14:45:34 +05:30
Sabiha Khan
4ff1f576f0 docs: add telnyx to telephony providers supporting call transfer 2026-05-14 09:55:20 +05:30
Sabiha Khan
80c9f2c2ad
chore(main): release dograh 1.29.0 (#275) 2026-05-13 22:36:07 +05:30
Abhishek Kumar
b728cc4922 chore: fix ARI documentation 2026-05-13 21:53:18 +05:30
Sabiha Khan
ebeffdbc40
fix(ari): pre-register ext channel id and defer bridge to its StasisS… (#284)
* fix(ari): pre-register ext channel id and defer bridge to its StasisStart

Two race conditions in the inbound ARI flow could leave a call silent:

1. Bridging both channels immediately after creating the ext media leg
   raced against the ext channel entering the Stasis application; slow
   chan_websocket handshakes produced "Channel not in Stasis application"
   422 errors on addChannel.

2. Asterisk could fire StasisStart for the ext channel before the
   externalMedia POST response returned, so _is_ext_channel returned
   False and the event was dropped as an unknown outbound call.

Fixes:
- Generate the ext channel id as dograh-ext-<uuid> client-side and pass
  it to Asterisk via the channelId query param. Mark the ext channel,
  set its channel->run mapping, register the pending bridge entry, and
  persist gathered_context.ext_channel_id all before the POST.
- Defer the bridge to a new _complete_bridge_after_ext_ready handler
  triggered by the ext channel's own StasisStart. Both channels are
  guaranteed in Stasis by then, so addChannel cannot 422.
- On POST failure or channelId mismatch, roll back the pending entry
  and ERROR loudly.

* fix: replace in-memory dict with redis storage
2026-05-13 18:33:34 +05:30
Abhishek
59619e9eaa
feat: an option to setup remote server with docker compose build (#280)
* feat: remote setup with docker build option

* chore: update documentation

* chore: make script run in non tty

* chore: add warning about slow build

* chore: add more documentation

* feat: add FASTAPI_WORKERS parameter

* feat: add scaling docs

* feat: add update script

* fix: fix semver options in update_remote.sh
2026-05-13 17:22:14 +05:30
Sabiha Khan
b670004725
feat: verify telnyx webhook signature optionally (#279) 2026-05-12 19:47:28 +05:30
Abhishek Kumar
7249a9f8ed chore: add campaign id in render context for webhook 2026-05-12 19:32:41 +05:30
Abhishek
7f0dac1ad5
feat: configurable ElevenLabs base URL for Data Residency (#278)
* feat: configurable ElevenLabs base URL for Data Residency (#269)

Adds a `base_url` field to `ElevenlabsTTSConfiguration` so users on an
ElevenLabs Data Residency plan (EU, etc.) can point Dograh at the
regional endpoint instead of the hardcoded global one. Defaults to
`https://api.elevenlabs.io`, preserving existing behaviour. The
service factory rewrites the HTTP scheme to WSS when constructing the
WebSocket TTS service.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* fix: fix drift

---------

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-12 19:01:13 +05:30
spuice
f2cb6499e1
feat: inline rename of workflow on the editor page (#273)
* feat: inline rename of workflow on the editor page

Add a pencil icon next to the workflow name in
WorkflowEditorHeader.tsx. Clicking it swaps the <h1> for an inline
<Input> that saves on Enter or Blur, cancels on Esc, validates
empty/whitespace input, skips no-op renames, rolls back on API
error, and guards against double-submit. Reuses
saveWorkflowConfigurations (the existing rename path used by the
Settings page) — no parallel API call.

Closes https://github.com/dograh-hq/dograh/issues/252.

* refactor: collapse rename state and remove silent config fallback

- WorkflowEditorHeader: replace (isEditingName, nameDraft, nameError,
  isRenaming) with a single discriminated-union state. Error and saving
  were mutually exclusive and both meaningless in display mode; the
  union makes the bad combinations unrepresentable and structurally
  prevents the Enter -> disable-input -> blur -> re-fire race that the
  original code only guarded against by convention.

- RenderWorkflow: drop the `?? DEFAULT_WORKFLOW_CONFIGURATIONS` fallback
  in renameWorkflow. In normal flow the store is initialized before the
  header renders, but if it ever weren't, the fallback would silently
  overwrite the server-side config with defaults. Throw instead so the
  header's existing catch surfaces a toast.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Abhishek Kumar <abhishek@a6k.me>
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-12 18:54:12 +05:30