Skip to content

Separate audio client functions #100

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

ngoiyaeric
Copy link

Add separate request structs for transcription and translation functions.

Add TranscriptionRequest struct to handle transcription-specific parameters in groq.go.
Add TranslationRequest struct to handle translation-specific parameters in groq.go.
Update Transcribe function to use TranscriptionRequest in groq.go.
Update Translate function to use TranslationRequest in groq.go.
Modify callAudioAPI function to handle both TranscriptionRequest and TranslationRequest in groq.go.
Add unit tests for TranscriptionRequest and TranslationRequest in inference_test.go.
Add TranscriptionRequest and TranslationRequest struct definitions in types.go.

Convert tool calls to asynchronous execution using goroutines and unbuffered channels.

* **`examples/composio-github-star/main.go`**
  - Add unbuffered channels for `comp.Run` tool call.
  - Execute `comp.Run` tool call in a goroutine.
  - Receive the result from the unbuffered channel.

* **`examples/e2b-go-project/main.go`**
  - Add unbuffered channels for `sb.RunTooling` tool call.
  - Execute `sb.RunTooling` tool call in a goroutine.
  - Receive the result from the unbuffered channel.

* **`examples/toolhouse-python-code-interpreter/main.go`**
  - Add unbuffered channels for `ext.Run` tool call.
  - Execute `ext.Run` tool call in a goroutine.
  - Receive the result from the unbuffered channel.

* **`extensions/composio/run.go`**
  - Add unbuffered channels for `comp.Run` tool call.
  - Execute `comp.Run` tool call in a goroutine.
  - Receive the result from the unbuffered channel.
Turn all tool calls into go routine on unbuffured channels
Add a method to signify task completion by an LLM.

* **groq.go**
  - Add `TaskCompletionEndpoint` field to `Client` struct.
  - Initialize `TaskCompletionEndpoint` in `NewClient` function.
  - Implement `SignifyTaskCompletion` method in `Client` struct.

* **README.md**
  - Add documentation for `SignifyTaskCompletion` method.
  - Include an example usage of `SignifyTaskCompletion` method.

* **unit_test.go**
  - Add `TestSignifyTaskCompletion` to test successful task completion.
  - Add `handleSignifyTaskCompletionEndpoint` to handle the signify task completion endpoint.
  - Add `TestSignifyTaskCompletionError` to test task completion with an error response.
  - Add `handleSignifyTaskCompletionErrorEndpoint` to handle the signify task completion endpoint with an error response.
Add method to signify task completion by LLM
Revert "Turn all tool calls into go routine on unbuffured channels"
Add separate request structs for transcription and translation functions.

* Add `TranscriptionRequest` struct to handle transcription-specific parameters in `groq.go`.
* Add `TranslationRequest` struct to handle translation-specific parameters in `groq.go`.
* Update `Transcribe` function to use `TranscriptionRequest` in `groq.go`.
* Update `Translate` function to use `TranslationRequest` in `groq.go`.
* Modify `callAudioAPI` function to handle both `TranscriptionRequest` and `TranslationRequest` in `groq.go`.
* Add unit tests for `TranscriptionRequest` and `TranslationRequest` in `inference_test.go`.
* Add `TranscriptionRequest` and `TranslationRequest` struct definitions in `types.go`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant