Skip to content
Open
Show file tree
Hide file tree
Changes from 15 commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
5c593bc
Add inference model typings
toubatbrian Sep 15, 2025
2ff8a7c
add liscence
toubatbrian Sep 15, 2025
ff76855
add
toubatbrian Sep 16, 2025
35311df
add
toubatbrian Sep 16, 2025
dad1012
Update worker.ts
toubatbrian Sep 16, 2025
45f5bc7
Update _input.ts
toubatbrian Sep 16, 2025
32dc8fc
add
toubatbrian Sep 16, 2025
011b2c3
Merge branch 'brian/bump-lk-node' into brian/gateway-api
toubatbrian Sep 16, 2025
20a4d8c
Merge branch 'main' into brian/gateway-api
toubatbrian Sep 16, 2025
69a5d3c
Gateway LLM (#695)
toubatbrian Sep 18, 2025
982fb81
Merge branch 'main' into brian/gateway-api
toubatbrian Sep 18, 2025
6cf1ada
Update pnpm-lock.yaml
toubatbrian Sep 18, 2025
2abe17c
Update _input.ts
toubatbrian Sep 18, 2025
9634192
Update turbo.json
toubatbrian Sep 18, 2025
758520b
Gateway STT (#703)
toubatbrian Sep 18, 2025
fbe9d08
Gateway TTS (#704)
toubatbrian Sep 19, 2025
8110041
Minor Gateway API Tweak (#710)
toubatbrian Sep 19, 2025
fb9943f
Renaming Env Key with LIVEKIT_INFERENCE_ prefix (#711)
toubatbrian Sep 22, 2025
7a95a62
Update agents/src/inference/index.ts
toubatbrian Sep 23, 2025
01e9279
Update index.ts
toubatbrian Sep 23, 2025
5137671
add
toubatbrian Sep 23, 2025
36de581
Update llm.ts
toubatbrian Sep 23, 2025
94c53ca
remove unused listeners
toubatbrian Sep 23, 2025
d32c77e
Create yellow-wombats-wait.md
toubatbrian Sep 23, 2025
c839169
add assemblyai model
toubatbrian Sep 23, 2025
dca8fec
improve 'any' models typing
toubatbrian Sep 24, 2025
e89d2ce
Update agents/src/inference/llm.ts
toubatbrian Sep 24, 2025
7bfb3dc
Update llm.ts
toubatbrian Sep 24, 2025
f5a8ca5
Update llm.ts
toubatbrian Sep 24, 2025
b53f7dc
fix typing
toubatbrian Sep 24, 2025
f71db2d
Update README.md
toubatbrian Sep 24, 2025
fca6d10
Update README.md
toubatbrian Sep 24, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 25 additions & 1 deletion .cursor/rules/agent-core.mdc
Original file line number Diff line number Diff line change
Expand Up @@ -508,6 +508,30 @@ For more information, read the example agent file under the `examples` directory

`pnpm build && pnpm dlx tsx ./examples/src/my_agent.ts dev|download-files --log-level=debug|info(default)`


## License

Remember to always add the following header to the top of every newly added file.
```
// SPDX-FileCopyrightText: 2025 LiveKit, Inc.
//
// SPDX-License-Identifier: Apache-2.0
```

## Debugging Plugins

For plugin components such as STT, TTS, LLM. You can debug these individual components by creating a new example agent file under the `examples` directory. You do not need to have `defineAgent` function if you only want to debug individual plugin components, just run `pnpm build` and `node ./examples/src/test_my_plugin.ts` to test the plugin. Test file is prefixed with `test_`.
For plugin components such as STT, TTS, LLM. You can debug these individual components by creating a new example agent file under the `examples` directory. You do not need to have `defineAgent` function if you only want to debug individual plugin components, just run `pnpm build` and `node ./examples/src/test_my_plugin.ts` to test the plugin. Test file is prefixed with `test_`.

### Inference LLM Testing Guidelines

When testing the inference LLM (`inference.LLM`):

1. **Model Names**: Always use the full model names from `agents/src/inference/models.ts`. Use `'openai/gpt-4o-mini'` instead of just `'gpt-4o-mini'`.

2. **Logger Initialization**: Always initialize the logger before using any LLM functionality:
```typescript
import { initializeLogger } from '@livekit/agents';
initializeLogger({ pretty: true });
```

6. **Test Structure**: Include both basic streaming and tool calling tests to verify full functionality.
3 changes: 2 additions & 1 deletion agents/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,13 @@
},
"dependencies": {
"@livekit/mutex": "^1.1.1",
"@livekit/protocol": "^1.29.1",
"@livekit/protocol": "^1.41.0",
"@livekit/typed-emitter": "^3.0.0",
"@types/pidusage": "^2.0.5",
"commander": "^12.0.0",
"heap-js": "^2.6.0",
"json-schema": "^0.4.0",
"openai": "^4.91.1",
"livekit-server-sdk": "^2.13.3",
"pidusage": "^4.0.1",
"pino": "^8.19.0",
Expand Down
3 changes: 2 additions & 1 deletion agents/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
* @packageDocumentation
*/
import * as cli from './cli.js';
import * as inference from './inference/index.js';
import * as ipc from './ipc/index.js';
import * as llm from './llm/index.js';
import * as metrics from './metrics/index.js';
Expand All @@ -33,4 +34,4 @@ export * from './vad.js';
export * from './version.js';
export * from './worker.js';

export { cli, ipc, llm, metrics, stream, stt, tokenize, tts, voice };
export { cli, inference, ipc, llm, metrics, stream, stt, tokenize, tts, voice };
7 changes: 7 additions & 0 deletions agents/src/inference/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
// SPDX-FileCopyrightText: 2025 LiveKit, Inc.
//
// SPDX-License-Identifier: Apache-2.0
export { LLM, LLMStream } from './llm.js';
export type { GatewayOptions, InferenceLLMOptions } from './llm.js';
export type { LLMModels, STTLanguages, STTModels, TTSModels } from './models.js';
export { STT } from './stt.js';
Loading