> For the complete documentation index, see [llms.txt](https://dev.guardian.hedera.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://dev.guardian.hedera.com/static-spec-test/platform/ai-suggestions.md).

# AI Suggestions

## Get methodology suggestion

> Returns AI response to the current question

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"0.0.1"},"tags":[{"name":"ai-suggestions"}],"servers":[{"url":"/api/v1","description":"version 1.0"}],"paths":{"/ai-suggestions/ask":{"get":{"description":"Returns AI response to the current question","operationId":"AISuggestionsAPI_getAIAnswer","parameters":[{"name":"q","required":true,"in":"query","description":"The question of choosing a methodology","schema":{"type":"string"}}],"responses":{"200":{"description":"Successful operation. Returns a comma-separated list of suggested methodology codes.","content":{"application/json":{"schema":{"type":"string"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Get methodology suggestion","tags":["ai-suggestions"]}}},"components":{"schemas":{"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}}}
```

## Rebuild AI vector

> Rebuilds vector based on policy data in the DB

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"0.0.1"},"tags":[{"name":"ai-suggestions"}],"servers":[{"url":"/api/v1","description":"version 1.0"}],"paths":{"/ai-suggestions/rebuild-vector":{"put":{"description":"Rebuilds vector based on policy data in the DB","operationId":"AISuggestionsAPI_rebuildVector","parameters":[],"responses":{"200":{"description":"Successful operation. Returns true when vector rebuild is complete.","content":{"application/json":{"schema":{"type":"boolean"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Rebuild AI vector","tags":["ai-suggestions"]}}},"components":{"schemas":{"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}}}
```
