#custom instructions in custom gpts

1 messages · Page 1 of 1 (latest)

vague grail
#

I am exploring the possibility of integrating a chatbot into a training program, designed to assist learners who are required to undertake professional development for specific reasons. The idea is to enable these learners to engage in a 15-minute learning session with the chatbot, where their interaction time could be tracked and logged. Furthermore, we are considering the potential of uploading domain-specific knowledge documents into a custom GPT model, enabling the chatbot to access and leverage this specialized information during interactions. Our question revolves around the reliability of the chatbot consistently referring to the uploaded domain knowledge throughout a session. We understand that general world knowledge will also contribute to the chatbot’s responses, but we are interested in whether there is a method to distinctly mark or differentiate the domain-specific information used in the chatbot’s replies. Is such a setup feasible?

What else is there to know about domain knowledge in relation to custom GPTs?

gusty willowBOT
#

Hi @vague grail. I'm kapa.ai, your friendly support bot. I will try to answer your question by searching through the knowledge base. :wave:

#

Yes, it is feasible to integrate a chatbot into a training program and upload domain-specific knowledge documents into a custom GPT model. This allows the chatbot to access and leverage this specialized information during interactions. However, it's important to note that the GPT model does not "learn" over time, no matter how often it is used or what feedback is provided. Each conversation is an "instance" of the model, and it does not exchange information between any instances of a model. The knowledge files become instantly retrievable as context, but the prompting helps you express how the GPT should use this context provided[^1^].

There are two main platforms for OpenAI's GPT models: chat.openai.com and platform.openai.com[^2^]. The chat.openai.com platform allows you to use a custom GPT with a user interface, and it's accessible only to GPT+ users. You can add all your stuff to the instructions (limited to 8000 characters), upload additional knowledge in the form of document uploads, or create a custom action that allows the model to pull information into the chat[^2^].

The platform.openai.com platform allows you to use assistants and chat completions. You can add stuff to the instructions, add files for retrieval (same as chatgpt knowledge), or create a tool that retrieves stuff contextually from an external database[^2^].

In terms of differentiating the domain-specific information used in the chatbot’s replies, it might be challenging as the GPT models generate responses based on the context provided and do not have a built-in mechanism to mark or differentiate the source of the information. However, you could potentially design your prompts or instructions in a way that encourages the model to reference the source of the information in its responses.

#

@vague grail kapa.ai is still learning and improving, please let us know how it did by reacting below

vague grail
#

@gusty willow I’m planning to utilize ChatGPT with custom GPT capabilities, without using the API, to enforce specific structures in responses and the dialogue process. This would involve data analysis by ChatGPT, which would read in predefined structures through JSON code.

Additionally, I aim to input certain behaviors via custom instructions, such as the learning companion’s behavior, motivation techniques, and pedagogical methods.

I also intend to provide domain knowledge as a document, from which the learning companion will compile the educational content.

Could you advise if this approach is feasible, and how best to implement it?

gusty willowBOT
#

Let me check the knowledge base for you. One moment! :books:

#

Yes, your approach is feasible. You can utilize ChatGPT with custom GPT capabilities to enforce specific structures in responses and the dialogue process. This can be achieved by providing custom instructions and uploading domain-specific knowledge documents.

Here's how you can implement it:

  1. Custom Instructions: You can set custom instructions to guide the behavior of your GPT. This can include the learning companion’s behavior, motivation techniques, and pedagogical methods. Custom instructions are available to all Plus users and can be enabled in the 'Profile & Settings' under 'Beta features'[^1^].

  2. Domain Knowledge: You can upload domain-specific knowledge documents to the GPT. This will allow the learning companion to compile the educational content based on the uploaded documents[^2^].

  3. Data Analysis: While GPTs can perform some level of data analysis, it's important to note that their capabilities are limited to the information provided in the conversation and the uploaded documents. They do not have the ability to access external databases or APIs unless you define custom actions[^3^].

  4. JSON Code: If you're planning to read in predefined structures through JSON code, you might need to use the API. Custom GPTs are exclusive to the ChatGPT interface, so if you want to integrate GPT into a different interface, the API is your only option[^4^].

Remember, no coding skills are required to create GPTs, making it accessible to experts in any field or anyone with a passion for a topic. For developers, additional customization is possible through coding actions that connect GPTs to external data or services[^2^].

#

^1^]: [Help Article > En > Articles > Custom instructions are rolling out in beta (July 20, 2023) (https://help.openai.com/en/articles/6825453-chatgpt-release-notes#h_647a58ba8a)
^2^]: [Help Article > En > Articles > GPTs FAQ (https://help.openai.com/en/articles/8554407-gpts-faq#h_40756527ce)
^3^]: [Docs > Actions > Actions in GPTs > Introduction (https://platform.openai.com/docs/actions/introduction)
^4^]: [Forum Post: Building a GPT vs. OpenAI API > Official Answer (https://community.openai.com/t/601866)

Note: you can ask me a follow up question by @ mentioning me again :speech_balloon:

#

@vague grail kapa.ai is still learning and improving, please let us know how it did by reacting below

vague grail
#

@gusty willow As a Plus user, I’m interested in accessing and utilizing the API within my current subscription without incurring additional costs. Could you provide guidance on how to gain access to the API as part of the Plus subscription, and clarify if this usage is included or if it might lead to extra charges?

Furthermore, I’m curious about the technical aspects of integrating and using the API:

•    Where is the API typically connected or integrated? Is it through a specific platform or service?
•    How can I invoke the API, especially considering I don’t have a website? Is there a way to test the API functionalities in a simple or cost-free environment, possibly without needing to set up a full website?

Any advice or resources for a beginner looking to explore API integration in a straightforward and cost-effective manner would be greatly appreciated.

gusty willowBOT
#

Let me check the knowledge base for you. One moment! :books:

#

The ChatGPT Plus subscription and the ChatGPT API are billed separately[^1^][^2^]. The Plus subscription covers usage on chat.openai.com only and costs $20/month[^1^][^2^]. The API usage is its own separate cost[^1^][^2^]. Therefore, accessing and utilizing the API within your current Plus subscription would incur additional costs[^1^][^2^].

To access the ChatGPT API, you can visit the OpenAI Platform and sign up or log in[^2^]. The API allows developers to integrate ChatGPT into their own applications, products, or services[^2^].

As for the technical aspects of integrating and using the API:

  • The API is typically connected or integrated into your own applications, products, or services[^2^]. This could be a web application, a mobile app, a desktop application, or any other software that can make HTTP requests.

  • You don't need a website to invoke the API. You can use tools like Postman or curl in a terminal to make API requests. You can also write a script in a programming language like Python or JavaScript to make API requests.

  • To test the API functionalities in a simple or cost-free environment, you can use the OpenAI Playground[^2^]. However, please note that usage of the API in the Playground is not free and will be billed according to the API pricing[^1^][^2^].

For beginners looking to explore API integration, OpenAI provides a Quickstart guide[^3^] and documentation on rate limits and usage tiers[^3^].

#

@vague grail kapa.ai is still learning and improving, please let us know how it did by reacting below

vague grail
#

@gusty willow Given that using the API would incur additional costs beyond my Plus subscription, it seems I’ll have to forego including it in my approach. With this in mind, how can the code interpreter feature assist me instead? Is there a way to use it to influence the response behavior of the AI to align with my objectives?

gusty willowBOT
#

Let me check the knowledge base for you. One moment! :books:

#

Yes, the Code Interpreter feature can be a valuable tool in your approach. Code Interpreter allows the Assistants API to write and run Python code in a sandboxed execution environment[^1^][^2^]. This tool can process files with diverse data and formatting, and generate files with data and images of graphs[^1^]. Code Interpreter allows your Assistant to run code iteratively to solve challenging code and math problems[^1^].

To enable Code Interpreter, you need to pass the code_interpreter in the tools parameter of the Assistant object[^3^]. Here's an example of how to do it:

assistant = client.beta.assistants.create(
 instructions="You are a personal math tutor. When asked a math question, write and run code to answer the question.",
 model="gpt-4-turbo-preview",
 tools=[{"type": "code_interpreter"}]
)

[^3^]

The model then decides when to invoke Code Interpreter in a Run based on the nature of the user request. This behavior can be promoted by prompting in the Assistant's instructions (e.g., “write code to solve this problem”)[^3^].

Please note that usage of OpenAI-hosted tools like Code Interpreter comes at an additional fee[^1^][^2^]. Each session is active by default for one hour, which means that you only pay for one session per if users interact with Code Interpreter in the same thread for up to one hour[^1^][^2^].

^1^]: [Docs > Assistants > Tools Beta (https://platform.openai.com/docs/assistants/tools)
^2^]: [Help Article > En > Articles (https://help.openai.com/en/articles/8550641-assistants-api)
^3^]: [Docs > Assistants > Tools Beta > Enabling Code Interpreter (https://platform.openai.com/docs/assistants/tools)

Note: you can ask me a follow up question by @ mentioning me again :speech_balloon:

#

@vague grail kapa.ai is still learning and improving, please let us know how it did by reacting below

vague grail
#

@gusty willow I understand the potential of the Code Interpreter feature and the API, but for my current project, I’m specifically interested in utilizing the capabilities of the Custom GPT interface without employing the API or Playground. My goal is to shape the AI’s response behavior directly through the interface, leveraging custom prompts and instructions. Could you provide guidance on optimizing the AI’s responses within this framework, focusing on crafting effective prompts and utilizing any available customization features in the Custom GPT interface to guide the learning process?

gusty willowBOT
#

Let me check the knowledge base for you. One moment! :books:

#

Absolutely, you can shape the AI's response behavior directly through the Custom GPT interface by leveraging custom prompts and instructions. Here are some best practices for prompt engineering with the OpenAI API that can be applied to the Custom GPT interface:

  1. Be More Specific: The more specific your instructions, the better the model can respond. For example, if you want the output to be a comma-separated list, ask it to return a comma-separated list[^1^].

  2. Provide Context: Help the model understand the bigger picture of your request. This could be background information, examples/demonstrations of what you want, or explaining the purpose of your task[^1^].

  3. Ask the Model to Answer as if it was an Expert: Explicitly asking the model to produce high-quality output or output as if it was written by an expert can induce the model to give higher quality answers that it thinks an expert would write[^1^].

  4. Prompt the Model to Write Down the Series of Steps Explaining its Reasoning: If understanding the 'why' behind an answer is important, prompt the model to include its reasoning. This can be done by simply adding a line like "Let's think step by step" before each answer[^1^].

In addition to these, OpenAI has started to roll out custom instructions, giving you more control over ChatGPT’s responses[^2^]. You can set your preferences once, and they’ll steer future conversations[^2^]. This feature is available to all Plus users[^2^].

Remember, each person’s use-case is different, so you might need to give it some thought to decide what would be worth the trade-off[^3^].

#

^1^]: [How to work with large language models > Code Capabilities > More prompt advice (https://cookbook.openai.com/articles/how_to_work_with_large_language_models#more-prompt-advice)
^2^]: [Custom instructions are rolling out in beta (July 20, 2023) (https://help.openai.com/en/articles/6825453-chatgpt-release-notes#h_647a58ba8a)
^3^]: [Building a CustomGPT with RAG - Please Help > Official Answer (https://community.openai.com/t/631349)

Note: you can ask me a follow up question by @ mentioning me again :speech_balloon:

#

@vague grail kapa.ai is still learning and improving, please let us know how it did by reacting below

vague grail
#

@gusty willow How can I use domain knowledge as a source of information and provide instructions for the AI's behavior within the Custom GPT environment? I'm looking to leverage specialized knowledge to inform the AI's responses and guide its interaction style.

gusty willowBOT
#

Let me check the knowledge base for you. One moment! :books:

#

In the Custom GPT environment, you can leverage domain knowledge and provide instructions for the AI's behavior in the following ways:

  1. Domain Knowledge: You can upload domain-specific knowledge documents to the GPT. This allows the GPT to reference this specialized information during interactions[^1^]. The content from the files that are uploaded could be included in the output[^4^].

  2. Custom Instructions: You can provide detailed instructions or guidelines on how the GPT should behave, its functionalities, and any particular behaviors to avoid[^4^]. Custom Instructions allow you to provide ChatGPT with direct guidance on what you’d like it to know about you and how you’d like it to respond[^5^][^6^]. For explicit information or instructions, you can add it to your Custom Instructions[^5^][^6^].

  3. Prompt Engineering: The input prompt is the best lever for improving model outputs[^1^]. You can try tricks like being more specific, providing context, asking the model to answer as if it was an expert, and prompting the model to write down the series of steps explaining its reasoning[^1^].

Remember, the GPT models generate responses based on the context provided and do not have a built-in mechanism to mark or differentiate the source of the information. However, you could potentially design your prompts or instructions in a way that encourages the model to reference the source of the information in its responses.

#

^1^]: [How to work with large language models > Code Capabilities > More prompt advice (https://cookbook.openai.com/articles/how_to_work_with_large_language_models#more-prompt-advice)
^4^]: [Help Article > En > Articles > Settings in the Configure tab (https://help.openai.com/en/articles/8554397-creating-a-gpt#h_9fdf0ceaf0)
^5^]: [Help Article > En > Articles > Make responses with your chats more helpful > Is memory different from Custom Instructions? (https://help.openai.com/en/articles/8590148-memory-faq#h_863a5e4ee0)
^6^]: [Help Article > En > Articles > Frequently asked questions > What is the benefit of using custom instructions? (https://help.openai.com/en/articles/8096356-custom-instructions-for-chatgpt#h_50e56363e4)

Note: you can ask me a follow up question by @ mentioning me again :speech_balloon: