-
Notifications
You must be signed in to change notification settings - Fork 300
Description
Summary: The existing wit_get_query_results_by_id function returns complete work item details, which creates large payloads when queries have many work items. We need a lightweight alternative that returns only work item IDs.
Current Behavior:
wit_get_query_results_by_idreturns full query results with all work item details- Large queries result in excessive data transfer and slow response times
- Large queries result overwhelms the LLM (Language Learning Model) with too much context
- Unnecessary data is included when users only need work item IDs for further processing
Proposed Solution: Add a new function wit_get_query_ids_by_id with these characteristics:
Function Name: wit_get_query_ids_by_id
Description: "Retrieve only the work item IDs from a query result. This is a lightweight alternative to get_query_results_by_id when you only need the IDs."
Parameters:
id(required): The query IDproject(optional): Project name or IDteam(optional): Team name or IDtimePrecision(optional): Include time precisiontop(optional): Maximum number of results (default: 50)
Return Format:
{
"ids": [12345, 67890, 11111],
"count": 3
}Benefits:
- Significantly reduced response payload size
- Faster query execution and data transfer
- Prevents LLM context window overflow with large result sets
- IDs can be used directly with
wit_get_work_items_batch_by_idsfor selective detail retrieval - Maintains backward compatibility (original function unchanged)
Implementation: The function calls the same API as wit_get_query_results_by_id but extracts only the IDs from queryResult.workItems array.
Instead of returning full details for potentially hundreds of work items, return just the array of IDs for efficient processing by AI assistants and other tools.