Rasa Clam Tutorial Can Not connect openai with vpn proxy

When using Rasa Pro to experiment with the CLAM tutorial, I found that I couldn’t connect to OpenAI after setting up the VPN. The error was as follows. However, when I run a separate test program for OpenAI, it successfully connects through the proxy! please help me !

2024-08-27 15:33:41 ERROR rasa.dialogue_understanding.generator.flow_retrieval - [error ] Cannot fetch flows from vector store error=APIConnectionError(message=‘Error communicating with OpenAI’, http_status=None, request_id=None) error_type=APIConnectionError event_key=flow_retrieval.query_vector_store.error query=?

We’re glad to see you trying the tutorial! Can you share the contents of your config.yml and details of your VPN configuration?

my config.yml is :


(rasa_clam) king@bogon rasa-clam-test % cat config.yml recipe: default.v1 language: en pipeline:

  • name: SingleStepLLMCommandGenerator llm: model_name: gpt-4 flow_retrieval: active: true policies:
  • name: FlowPolicy assistant_id: 20240827-150843-aquamarine-delta

my vpn is clash verge , use “globle mode” and “system proxy”
export https_proxy=http://127.0.0.1:7897 http_proxy=http://127.0.0.1:7897 all_proxy=socks5://127.0.0.1:7897 It should not be a VPN issue because the example program I wrote can access OpenAI without any problems

thank you

I figured it out. Rasa Pro uses OpenAI SDK 0.28, and based on the code, its asynchronous interface does not support proxies set via environment variables; proxies can only be configured through openai.proxy. I hope that Rasa Pro Clam can support proxy configuration settings. :slight_smile: