litellm - 💡(How to fix) Fix [Feature]: Wrap ACP provider as a model API [1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
BerriAI/litellm#23458Fetched 2026-04-08 00:44:09
View on GitHub
Comments
0
Participants
1
Timeline
3
Reactions
2
Author
Participants
Timeline (top)
labeled ×3
RAW_BUFFERClick to expand / collapse

Check for existing issues

  • I have searched the existing issues and checked that my issue is not a duplicate.

The Feature

I would like to be able to use an ACP provider as just another model.

Motivation, pitch

Several tools, e.g. Gemini CLI, get preferential access to models with better pricing. They limit how the models can be used outside of that. However, they expose an ACP interface. ACP can be used to implement an OpenAI compatible API, and probably the rest too. This would allow us to use those models "directly".

What part of LiteLLM is this about?

Proxy

LiteLLM is hiring a founding backend engineer, are you interested in joining us and shipping to all our users?

No

Twitter / LinkedIn details

No response

extent analysis

Fix Plan

To integrate an ACP provider as another model, we need to create an adapter that maps the ACP interface to our existing model API.

Steps

  • Create a new class AcpModelAdapter that implements the Model interface
  • Implement the AcpModelAdapter class to forward requests to the ACP provider
  • Register the AcpModelAdapter class as a model in the proxy

Example Code

class AcpModelAdapter(Model):
    def __init__(self, acp_provider):
        self.acp_provider = acp_provider

    def generate(self, prompt):
        # Forward the generate request to the ACP provider
        response = self.acp_provider.generate(prompt)
        return response

    def get_model_info(self):
        # Return model info from the ACP provider
        return self.acp_provider.get_model_info()

# Register the AcpModelAdapter class as a model
proxy.register_model('acp-model', AcpModelAdapter(acp_provider))

Verification

To verify that the fix worked, test the AcpModelAdapter class by sending requests to the proxy and checking that the responses match the expected output from the ACP provider.

Extra Tips

  • Make sure to handle errors and exceptions properly when forwarding requests to the ACP provider
  • Consider adding caching or other optimizations to improve performance
  • Document the AcpModelAdapter class and its usage in the proxy API documentation.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING