Skip to content

Instantly share code, notes, and snippets.

@fabiofa87
Last active January 2, 2024 16:47
Show Gist options
  • Save fabiofa87/7ada887664822af9f9a20b2efa55ac84 to your computer and use it in GitHub Desktop.
Save fabiofa87/7ada887664822af9f9a20b2efa55ac84 to your computer and use it in GitHub Desktop.

Application ID

dce4893f-2e60-4c6a-9167-72db2c5f277f

Template ID

fd6ab2ab-b2c2-4f40-a9bd-0b8034ffc2e1

Template prompt:

  • "prompt":
  • "Answer the question based ONLY on the context provided below.\n
  • Questions related to subjects other than: BrewDocs, BrewDat, GitHub access management, Lakehouse architecture and Delta Share should be considered OUT-OF-SCOPE and should ALWAYS be answered with "I don't know".\n
  • Subjects such as: Music, Games, Sports and Politics should be considered OUT-OF-SCOPE and should ALWAYS be answered with "I dont't know".\n
  • Questions related to "Unity" should ALWAYS be interpreted in the context of the BrewDocs Unity Catalog, NEVER in the context of the Unity Game Engine. If the question cannot be answered using the information provided, or if it is OUT-OF-SCOPE, answer with "I don't know"", "description": "Template for brewdat", "context": "BDOCS",

Connector ID

1375c8e6-f354-433f-a795-9daec0a9e6bb Name: Bdocs Connector

Como rodar?

  • Ao rodar o RAG, colocar meu NGROK que está rodando o orchestrator LOCALMENTE na minha máquina, passando o application id e connector id para bater nos endpoints - embeddings/get answer

Postman

Etapas

1- Criar application, caso não exista. Está localizada na pasta do IDENTITY

2- Criar connector utilizando o application id criado

3- Criar template adicionando o context adequado e o prompt desejado

4- Editar connector como no exemplo abaixo:

{
    "id": "1375c8e6-f354-433f-a795-9daec0a9e6bb",
    "applicationId": "dce4893f-2e60-4c6a-9167-72db2c5f277f",
    "name": "bdocs",
    "baseUrl": "<endereco de dev>/api",
    "methods": [
        {
            "path": "knowledge/ask",
            "type": 1
        }
    ],
    "version": 2,
    "timeStamp": "2024-01-02T16:23:46.1193199Z",
    "aggregateId": "1375c8e6-f354-433f-a795-9daec0a9e6bb"
}

5- Testar se está OK usando endpoint do completion

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment