code_utils
autogen.code_utils.generate_code
generate_code
(openai<1)
Generate code.
Name | Description |
---|---|
pattern | The regular expression pattern for finding the code block. The default pattern is for finding a code block in a markdown file. Type: str Default: ‘ [ \\t]*(\\w+)?[ \\t]*\\r?\\n(.*?)\\r?\\n[ \\t]* ’ |
**config |
Type | Description |
---|---|
tuple[str, float] | str: The generated code. float: The cost of the generation. |