> For the complete documentation index, see [llms.txt](https://docs.gdf.ai/gdf-full-stack-engineering/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.gdf.ai/gdf-full-stack-engineering/intro-to-gdf-fse/access-a-chat-based-llm.md).

# Access a Chat Based LLM

Before we dive into the documentation, be sure you have a chat-based Large Language Model (LLM) environment set up. This could be a service you sign up for online (like ChatGPT) or a locally hosted open-source model—whatever suits your needs. Once you have an environment running, you should have a console or interface in which you can type prompts and receive responses.

Most chat-based LLMs provide:

* A text input area (where you type your prompts).
* A workspace that keeps track of your ongoing conversation.
* The ability to generate responses based on your most recent input and the conversation history.

For example, if you want to test your setup, you might type something like:

> **"Write some lyrics in the style of Metallica."**

After the model responds, you can follow up with:

> **"Rewrite the above in the style of Dr. Seuss."**

Observe how the LLM’s response changes based on the conversation history. If you see appropriate responses, then your environment is working as expected!

This idea of “remembering” previous prompts and responses is crucial for developers. We often refer back to previously generated snippets—whether it’s debugging an exception, converting code from one language to another, or integrating a new library. The technical term for a model’s ability to incorporate previous conversation text is called **prompt context**, and it’s one of five key prompting concepts we’ll explore in more detail throughout this documentation.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.gdf.ai/gdf-full-stack-engineering/intro-to-gdf-fse/access-a-chat-based-llm.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
