Anyone familiar with examples / previous work where Custom ChatGPT code generation has been shaped by rules/specifications of some flavor?

Thank you!

It sounds like I should try something like below. Simple, short instructions to ChatGPT on what it should do. Then in a separate training document in the knowledge base locate a description of the algorithm blocks with pointers to code blocks, something like below.

XXXXXXXXXXXXX Instructions:

Do
X
Y
Z

XXXXXXXXXXXXX Knowledge File:

To do X, consider these approaches:
X1 (concise description of algorithm, perhaps pseudo code)
X2
XN

To do X1, consider these sample implementations:
CODE_BLOCKX1A
CODE_BLOCKX1B…