Document

The structure of a Technique document

Technique

The foundational element in the Technique language is a technique. A valid technique is, at its top-level, either:

  • a series of steps; or

  • a procedure.

Technique Document

A file containing a procedure written in the Technique language is called a document. Its content is:

  • a metadata header; and

  • a technique.

The extension used to identify a file as containing a Technique document is .tq.

By convention, files containing Technique documents are named in Proper Case. Because document names are also used as part of the stable address for a procedure in external references, their filenames are to be written without spaces. Thus Lunchtime.tq, GargleBlaster.tq, and PoetryAppreciationProcedure.tq would all be appropriate, but documents named Magrathean Customer Service.tq or demolition.tq would not.

Technique Body

A document can thus contain either steps, or a procedure (which can contain steps). The following are all valid Technique documents. The first is just a series of steps:

% technique v1

    1. First Step
    2. Second Step
    3. Third Step

The second example also shows a "series of steps", this time with the level-above-step, section:

% technique v1

I. First Section

    1. First Step
    2. Second Step
    3. Third Step

II. Second Section

    1. Fourth Step
    2. Fifth Step
    3. Sixth Step

Finally we have a document whose technique contains a top-level procedure which then contains that same structure but declares each of its sections as their own procedures:

% technique v1

top_level :

I. First Section

first_thing :

    1. First Step
    2. Second Step
    3. Third Step

II. Second Section

second_thing :

    1. Fourth Step
    2. Fifth Step
    3. Sixth Step