Before you start
In TrustAI- A project. See Create a project.
- The Editor or Admin project role in it. A Viewer “Can open the project and read what is in it”, nothing more.
- To extract requirements from a document: credits in your workspace.
Add a requirement yourself
- Optional: make a suite first, to group requirements that belong together. Click the Create button (+) at the top right, then New suite. Enter a Name and click Create suite. You should see: the dialog’s note, “A suite groups requirements that belong together.”, then the message Created suite and the suite’s name. Once the project has a requirement, the new suite shows in the list, even while it’s empty. Requirements that aren’t in a suite are listed under Unassigned.
-
Click New requirement. In a new project it’s in the middle of the page. Later, it’s under Create at
the top right, or the + beside a suite’s name, which files the new requirement in that suite.
You should see: New requirement, with three fields:
- Name: a short name for the requirement.
- The suite, under the name: it shows Unassigned, or the suite whose + you clicked. Click it to choose one of your suites. It only lists suites you’ve already made: you can’t create a suite from here.
- Description (Markdown) (optional): say what must happen, in as much detail as you need.
-
Fill in at least the Name, then click Create requirement.
You should see: the requirement opens in a panel on the right, headed Requirement and its ID, such as
req-1, then its name. Under the name, the panel says Never evaluated and the coverage Not covered. In the list, it shows under its suite with the result Not evaluated.
Extract requirements from your documents
If you already have a product spec, policy or process document, TrustAI can read it and suggest requirements. You choose which to keep and which suite each one goes into.- In a new project, click Extract from your docs. In a project that already has requirements, click Import at the top right, then Generate requirements and scenarios from a document (agent evaluation) or Generate requirements and tests from a document (functional testing). You should see: Extract from a document: “Paste text or upload a document (a PRD, policy, or spec) and we’ll pull out the requirements.”
- Paste your text into Paste text, or click Upload a file. The dialog lists the file types it takes: PDF, Word, Markdown, text, CSV and JSON. Then click Extract requirements. You should see: “Reading the document…” while it works, then how many requirements it found, such as “4 requirements found.” Every suggestion is listed under Imported Requirements: “Each requirement goes into the suite it is listed under. Drag it into another suite, or into the trash to leave it out, then continue.” Your project’s suites are listed on the right, under Suites.
- Click a suggestion’s name to read it in full. Use the arrows, or Back to all requirements, to move around. You should see: Suggested requirement and its place in the list (such as 1 of 4), with its name, a Suite you can change, and a description. The description says what must happen, then lists Rules, Acceptance and Out of scope.
- Put each suggestion in a suite. Click Sort automatically to have TrustAI file them for you, or drag a suggestion onto one of your suites on the right. To move several at once, drag a box around them. You should see: after Sort automatically, a line such as “Sorted 3 requirements into 1 suite. 1 is left for you to place.” The suite on the right counts the suggestions now in it. Undo sort puts them back under Imported Requirements.
- Drag anything you don’t want onto Leave out (“Drag requirements here to leave them out.”). You should see: Leave out changes to say how many are left out, such as 1 left out, with “Drag one back to a suite to import it.”
- Click Continue. Discard closes the dialog without saving any of them. You should see: a message such as “3 requirements saved.” The saved requirements are in your list under the suites you chose, each with a new ID and Not evaluated. In our walkthrough, nothing was left under Imported Requirements, and no suite of that name was made.
- TrustAI then offers to write a first scenario or test for each requirement you just saved. It warns that this is billed on its own and uses credits for each draft, and that it doesn’t show a price before you confirm. Click Generate scenarios or Generate tests to go ahead, or Not now to keep only the requirements. You should see: if you go ahead, a list of drafts, each marked “Ready to review or save.” with its coverage. Tick the drafts you want and click Save (it counts them, such as Save 1 scenario). Each saved draft is then marked “Saved.” Then click Done.
Import from OpenAPI (functional testing)
In a functional testing project that has a requirement, Import also offers Import from OpenAPI. It turns an OpenAPI document’s operations into a test, and you review the test before anything is saved or run. It takes a JSON or YAML file. It needs an API target in the project first. Without one, it says “This project has no API target” and asks you to add one in the project’s connections. Agent evaluation projects don’t have this option.Edit a requirement
Click a requirement in the list to open its panel. Its name is at the top. To rename it, double-click the name, or click it and press F2. Type the new name and press Enter. Esc leaves the name as it was. You should see: the message Renamed to and the new name, such as Renamed to “An Account must have a name”, and the new name in the list. The panel has three tabs:- Definition: its Coverage, Suite and Description.
- Click the description to change it, then click Save. If you click Cancel instead, TrustAI asks Discard changes?: “Your changes to this requirement’s definition aren’t saved. Discarding restores the saved definition.” Click Discard changes to drop your change, or Cancel to keep editing.
- Click the suite to move the requirement to another suite. It moves at once.
- Scenarios or Tests: what sits under it.
- Details: when it was created.
Reorder requirements
Drag a requirement’s row up or down among the requirements in its own suite, and drop it where you want it. There’s no separate handle: you drag the row itself. The new order stays after you reload the page. With Group by suite on, you can also drop a requirement into another suite’s group. It moves to that suite, with the message “Moved to” and the suite’s name. With Group by suite off, a requirement can only be dropped among its own suite’s requirements; a drop anywhere else does nothing. Dragging works only when the list’s order is Manual, which it is to begin with. To check, click Display options (next to the filter button at the top right) and look at Ordering. The same menu lets you turn Group by suite on or off and choose which columns to show.Select several requirements
Tick the box on a requirement’s row to select it. To select a run of rows, tick one, then hold Shift and tick another: every row between them is selected too. The box on a suite’s heading selects every requirement in that suite. You should see: a bar at the top of the list that counts what you selected, such as “4 requirements and 1 test selected”, with Run selected tests (functional testing) and Archive requirements. Clear selection (the × at the end of the bar) unticks them all.What Coverage and the result mean
Each requirement in the list shows two words. Coverage says whether the scenarios or tests under a requirement plan to check every part of it: Fully covered, Partially covered or Not covered. TrustAI’s AI works it out: point at the small mark beside Coverage in the requirement’s panel and it says “Analysed by AI”. Click the coverage in the panel to see why. In an agent evaluation project it lists the clauses it checked, for example “1 of 1 clauses are covered by a current scenario assessment.”, followed by each clause. In a functional testing project it checks the items under Acceptance (marked Only these are criteria), for example “Every acceptance criterion is covered by a test.” Coverage is a plan. It doesn’t tell you whether anything passed. The result says how the requirement did when it ran. A new requirement shows Not evaluated in the list, and its panel says Never evaluated. See Run tests and read results.How to write a good requirement
The requirements TrustAI writes from your documents show the shape it works best with. Follow it when you write your own:- One behavior per requirement. In our walkthrough, a document with three rules came back as three requirements, each with its own short name, such as “Open payroll case for wrong pay”.
- Start with a plain statement of when it applies and what must happen: “When an employee says their pay is wrong, the agent opens a payroll case and gives the employee the case number.”
- List the rules one per line, each one thing you could check: “The agent opens a payroll case when an employee says their pay is wrong.” “The agent tells the employee the case number.”
- Say how you’d know it worked, under Acceptance: “When an employee says their pay is wrong, a payroll case is created.”
- Say what’s out of scope, so nobody tests the wrong thing: “Resolving the payroll case.”
- Write “must never” rules as their own requirement, not as a note on another one.