# Code generation

{% hint style="warning" %}
**The code generation feature is aimed to increase the productivity of the developer in the model building life cycle. It is achieved by generating the repeated functions that are used in the cycle allowing developer to spend more time on exploring new methodologies to improve the model.**
{% endhint %}

## How to access the feature?

```
import sanatio.code_generation as gc
```

Code\_generation file has all the functions that you will need to generate a new cell in the jupyter notebook with the function definition or print the function definition you need.

## &#x20;Know the list of functions available

Sanatio has a function that will print the list of functions definitions that will be available in Sanatio. The required function can be called from the list.

```
import sanatio.code_generation as gc

gc.show_function_list()
```

![](https://2005638194-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Flt8549NQKqZ5PrjAIK50%2Fuploads%2FWHyw68q8mbwOhJ7IRRMQ%2Fimage.png?alt=media\&token=b0ace739-ca5c-4684-b1f9-b9f1b6bf3243)

## Generate a new cell with function definition

```
import sanatio.code_generation as gc

gc.generate_numericals_summary()
```

![](https://2005638194-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Flt8549NQKqZ5PrjAIK50%2Fuploads%2FwQCT2Lc3Aw59YYPD5keP%2Fimage.png?alt=media\&token=3abf3795-0ddb-439d-9894-85de20cd660c)

## Print a function defintion

```
import sanatio.code_generation as gc

gc.generate_numericals_summary(print_function=True)
```

![](https://2005638194-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Flt8549NQKqZ5PrjAIK50%2Fuploads%2FjdLRwKcIdLNKkxcCIhfk%2Fimage.png?alt=media\&token=b3f9dbaf-2a09-4f80-9e6e-b18e5727e527)


---

# Agent Instructions: 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:

```
GET https://fluid-ai.gitbook.io/fluid-ai-sanatio/features/code-generation.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
