Claude Chain Prompting

Hey,

I’m trying to do some chain prompting with Claude.

ChatGPT has their Thread ID, how does it work with Claude?

I’m trying to see if I can get better results by using some kind of chat history in the next prompt.

Building a flow for a client:

  • grabbing their current article.
  • translate
  • get the headlines
  • write the SEO article
  • re-write according to brand guidelines and historical examples.
  • add slug and alt text and other SEO variables for wordpress

Any tips on this?

Cheers,
André

Hi, In this case, you simply need to create a sequential chain of nodes, with each node’s result passed into the next node. There’s no need to retain the previous conversation’s context, as it could interfere with each node’s ability to perform its specific function.

Maintaining a conversation history is only necessary for building chatbots that support ongoing dialogue, where it makes sense to retain context.

To start, try creating a straightforward chain and assigning each node a specific role.

Btw here’s an example of a similar setup, but as a template using AI agents: Using AI Agents

You can set prompts in either the “system prompt” or the “user prompt” fields, and based on my tests, it doesn’t make a difference in performance

Additionally, I recommend adding a note at the end of each prompt, instructing the AI not to provide any additional commentary and to return only the response text. This way, each node will produce a clean result, focusing solely on the answer.

Awesome. Thanks for great feedback, and quickly. Will keep on building!

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.