danny-avila / rag_api

ID-based RAG FastAPI: Integration with Langchain and PostgreSQL/pgvector
https://librechat.ai/
MIT License
252 stars 105 forks source link

can't reuse files #82

Open jerowe opened 2 days ago

jerowe commented 2 days ago

Hello. Thanks for the great project!

I'm having an issue where I can upload a file and query it once.

The file persists in the file tab, but if I click on the file to try and reuse it I get an error saying "File size limit exceeded for endpoint : 0MB"

Screenshot 2024-10-01 at 1 14 51 PM

I did a fresh pull on all the docker images today. Any ideas for me?

danny-avila commented 2 days ago

Hi thanks for checking out the project. I can’t reproduce the issue, do you have a librechat.yaml file configured? If so could you share what you have?

jerowe commented 17 hours ago
# For more information, see the Configuration Guide:
# https://docs.librechat.ai/install/configuration/custom_config.html

# Configuration version (required)
version: 1.0.3

# Cache settings: Set to true to enable caching
cache: true

fileConfig:
  endpoints:
    default:
      disabled: false
      fileLimit: 5
      fileSizeLimit: 10
      totalSizeLimit: 50
      supportedMimeTypes:
        - "image/.*"
        - "application/pdf"
    assistants:
      disabled: false
      fileLimit: 5
      fileSizeLimit: 10
      totalSizeLimit: 50
      supportedMimeTypes:
        - "image/.*"
        - "application/pdf"
    openAI:
      disabled: true

# Definition of custom endpoints
endpoints:
  assistants:
    disableBuilder: true

  custom:
    - name: "KNOWLEDGEBASE_1"  # Unique name for the endpoint
      apiKey: "API_KEY"
      baseURL: "http://flask-api:3000/knowledgebase/"
      models:
        default:
          - anthropic.claude-3-5-sonnet-20240620-v1:0
          - anthropic.claude-3-haiku-20240307-v1:0
          - anthropic.claude-3-sonnet-20240229-v1:0
          - anthropic.claude-v2
          - mistral.mistral-large-2402-v1:0
          - meta.llama2-70b-chat-v1
        fetch: false  # Defaults to false.
      titleConvo: true  # Set to true to enable title conversation
      titleMethod: "functions"  # Defaults to "completion" if omitted.
      titleModel: "anthropic.claude-3-haiku-20240307-v1:0"  # Defaults to "gpt-3.5-turbo" if omitted.
      summarize: false
      summaryModel: "anthropic.claude-3-haiku-20240307-v1:0"  # Defaults to "gpt-3.5-turbo" if omitted.
      forcePrompt: false
      addParams:
        stream: false
        knowledge_base_id: 'ABCD'

    - name: "CHAT"  # Unique name for the endpoint"
      apiKey: "API_KEY"
      baseURL: "http://flask-api:3000/chat/"
      models:

        default:
          - anthropic.claude-3-5-sonnet-20240620-v1:0
          - anthropic.claude-3-haiku-20240307-v1:0
          - anthropic.claude-3-sonnet-20240229-v1:0
          - anthropic.claude-v2
          - mistral.mistral-large-2402-v1:0
          - meta.llama2-70b-chat-v1
        fetch: false  # Defaults to false.
      titleConvo: true  # Set to true to enable title conversation

      titleMethod: "functions"  # Defaults to "completion" if omitted.
      titleModel: "anthropic.claude-3-haiku-20240307-v1:0"  # Defaults to "gpt-3.5-turbo" if omitted.
      summarize: false
      #      summaryModel: "kb-1"  # Defaults to "gpt-3.5-turbo" if omitted.
      summaryModel: "anthropic.claude-3-haiku-20240307-v1:0"  # Defaults to "gpt-3.5-turbo" if omitted.
      forcePrompt: false
      #      modelDisplayLabel: "Terremoto KB"  # Default is "AI" when not set.
      addParams:
        safe_prompt: true # This field is specific to Mistral AI: https://docs.mistral.ai/api/
        stream: false
    - name: "KNOWLEDGEBASE_1"
      apiKey: "API_KEY"
      baseURL: "http://flask-api:3000/knowledgebase/"
      models:
        default:
          - anthropic.claude-3-5-sonnet-20240620-v1:0
          - anthropic.claude-3-haiku-20240307-v1:0
          - anthropic.claude-3-sonnet-20240229-v1:0
          - anthropic.claude-v2
          - mistral.mistral-large-2402-v1:0
          - meta.llama2-70b-chat-v1

        fetch: false  # Defaults to false.
      titleConvo: true  # Set to true to enable title conversation
      titleMethod: "functions"  # Defaults to "completion" if omitted.
      titleModel: "anthropic.claude-3-haiku-20240307-v1:0"  # Defaults to "gpt-3.5-turbo" if omitted.
      summarize: false
      summaryModel: "anthropic.claude-3-haiku-20240307-v1:0"  # Defaults to "gpt-3.5-turbo" if omitted.
      forcePrompt: false
      addParams:
        stream: false
        knowledge_base_id: "123456"