(data)
| 493 | |
| 494 | |
| 495 | def remove_structure_text(data): |
| 496 | if isinstance(data, dict): |
| 497 | data.pop('text', None) |
| 498 | if 'nodes' in data: |
| 499 | remove_structure_text(data['nodes']) |
| 500 | elif isinstance(data, list): |
| 501 | for item in data: |
| 502 | remove_structure_text(item) |
| 503 | return data |
| 504 | |
| 505 | |
| 506 | def check_token_limit(structure, limit=110000): |
no outgoing calls
no test coverage detected