# python: derive URL: https://generaltranslation.com/en-US/docs/python/api/derive.mdx --- title: derive description: API reference for the derive function --- ## Overview `derive` marks content as statically analyzable so that the GT CLI can extract all possible translation entries at build time. It is an **identity function** — it returns exactly what you pass in. Its purpose is as a marker for static analysis. ```python from gt_flask import derive, t # or from gt_fastapi message = t(f"The {derive('boy' if gender == 'male' else 'girl')} is playing.") ``` ## Reference ### Parameters ### Returns Returns `content` unchanged. The function is an identity — its purpose is as a marker for the CLI. --- ## Notes - All possible outcomes must be statically analyzable at build time - Dynamic content (user input, API data) inside `derive` should be wrapped with [`declare_var`](/docs/python/api/declare-var) - Use [`decode_vars`](/docs/python/api/decode-vars) to extract original values from declared variables - See the [derive tutorial](/docs/python/tutorials/derive) for detailed examples and usage patterns