• Skip to primary navigation
  • Skip to main content
  • Skip to footer
HAMK - Häme University of Applied Sciences

Digipedagogical guidelines

  • Suomi
MENUMENU
  • Home
  • Planning
  • Teaching and guidance
  • Content production
  • Content sharing

How does an agent know how to act correctly?


Kuuntele

How does an agent know how to act correctly?

bannerikuva, jossa vasemmalla teksti tekoäly ja lamppuikoni. Oikealla lähikuva kädestä, jossa abstrakti tekoälykuvio.

Article sections


    Kuuntele

    You can define multiple skills files for an AI agent , from which the agent chooses the appropriate course of action for the situation. This is often a better solution than one huge help file, as the agent’s behavior remains clearer, more modular, and easier to maintain.

    Why should the skills file be .md format?

    Because Markdown is a very suitable format for agent instructions:

    1. It’s clear to a human. You can open the file with any text editor, such as VS Code, Notepad, or Obsidian.
    2. It’s easy for artificial intelligence to read. Headings, lists, tables, and code blocks stand out clearly.
    3. It doesn’t contain unnecessary formatting code. Word files have a lot of hidden structure and formatting. In Markdown, the content is usually cleaner.
    4. It’s great for version control. If you use GitHub, changes to Markdown files are well visible: what has been added, removed, or edited.
    5. It supports modular instruction Each skill can be written in its own .mdfile

    The key principle is this:

    The agent’s main instruction should not try to include all the skills, but its job is to tell when which skills file is used.

    Recommended structure

    It is worth dividing the instructions into three levels:

    1. Agent’s main instruction

    The main guideline defines the agent’s role, general operating principles, and rules for how skills files are used.

    For example:

    You are an agent specializing in educational technology and the pedagogical use of artificial intelligence.
    
    Always use the most suitable skills file for the task. Do not try to solve the task with general information if a skills file contains more detailed operating instructions.
    
    Select the skills file based on the user's request as follows:
    
    - If the user requests to evaluate student work or prepare evaluation feedback, use the file skill_feedback.md.
    - If the user asks to edit the Moodle XML file, use the file skill_moodle_xml.md.
    - If the user asks to prepare a study course implementation plan, use the file skill_course_implemantation.md.
    - If the user requests to analyze privacy risks or the responsible use of artificial intelligence, use the file skill_data_protection_and_ai.md.
    - If the task does not fit into any skills file, answer based on the general instructions and, if necessary, say that a more detailed skills instruction is not available.
    

    2. Skills file directory or selection logic

    It is a good idea to add a separate “skills directory” to the main guide. It acts as a router for the agent.

    For example:

    Skills file usage:
    
    1. skill_feedback.md
    Use when the task is related to student feedback evaluation, assessment matrices, numerical assessment, assessment of learning outcomes or generating feedback texts.
    
    2. skill_moodle_xml.md
    Use when the task is related to Moodle XML questions, exam question formatting, multiple choice questions, gap assignments or XML structure correction.
    
    3. skill_course_implemantation.md
    Use when the task is related to the course schedule, weekly structure, workload calculation, learning tasks or the assessment as a whole.
    
    4. skill_data_protection_and_ai.md
    Use when the task is related to artificial intelligence risks, data protection, DPIA/FRIA assessment, student data processing or the organization's AI guidelines.
    

    3. Actual skills files

    Each skills file should be limited to one task type as much as possible.

    A good skills file usually includes these sections:

    # Skill: Creating Feedback on Student Work
    
    ## When to Use This
    Use this skill guide when a user asks to create feedback or apply an assessment matrix to a student's work.
    
    ## Goal
    Produce feedback that is reasoned, consistent, understandable to the student, and tied to the given assessment matrix.
    
    ## Procedure
    1. First read the assignment.
    2. Read the assessment Rubric.
    3. Read the student's response.
    4. Create feedback for each criterion separately.
    5. Give a justification for each feedback.
    6. Finally, summarize strengths and areas for improvement.
    
    ## Limitations
    Do not use external sources to create feedback unless specifically requested by the user.
    Do not invent content that is not in the student's text.
    If material is missing, tell what is missing.
    
    ## Output format
    Please provide your answer in the following format:
    
    - Criterion
    - Feedback
    - Justification
    - Improvement suggestion
    

    How does an agent choose the right skill?

    The agent should use simple decision logic:

    Before answering, determine:
    1. What is the user's primary goal?
    2. Does the goal relate to a skills file?
    3. If so, follow that skills file.
    4. If more than one skills file is appropriate, use the primary skill file and use the other as a supporting guide only.
    5. If no skill is appropriate, respond according to the general agent guide.
    

    It is worth writing this directly into the agent’s main instructions.

    If multiple skills are suitable for the same task

    In this case, it is a good idea to specify a priority order . Otherwise, the agent may combine instructions inconsistently.

    For example:

    If the assignment involves both Moodle XML format and pedagogical assessment:
    1. First use the pedagogical skill file to generate the content.
    2. Then use the Moodle XML skill file for technical formatting.
    3. The final output must be technically valid Moodle XML.
    

    Or:

    If the assignment is related to both data protection and the teacher's instructions:
    1. Primarily follow the data protection and AI risks skill instruction.
    2. Formulate the final result in a way that the teacher can understand in accordance with the general communication guidelines.
    

    Good main instruction for an agent

    For example, you could use a structure like this:

    You have several skills files in use. They contain task-specific action models.
    
    Before each response, identify the task type of the user's request and select the most appropriate skills file.
    
    Do not use skills files mechanically, but apply them according to the user's goal. If the user's request is unclear, make the best possible interpretation based on the given material.
    
    Selection of skills files:
    
    - Assessment and feedback → skill_feedback.md
    - Moodle XML and exam questions → skill_moodle_xml.md
    - Course planning → skill_course_implemantation.md
    - Data protection, AI risks and responsible artificial intelligence → skill_data_protection_and_ai.md
    - Communication texts and instructions → skill_communication.md
    
    If a task fits into more than one skill file, use the primary skill file according to the main goal of the task and the secondary skill file only as supplementary instructions.
    
    If no skills file fits the task, respond based on your general role and the user's request.

    Practical recommendation

    Keep one skill fairly short and specific. A good rule of thumb:

    one skill = one clear task type.

    For example, don’t make a single file named:

    skill_education_ai_moodle_assessment_data_protection.md

    but rather:

    skill_feedback.md
    skill_moodle_xml.md
    skill_privacy.md
    skill_course_planning.md
    skill_communication.md

    This makes it easier for the agent to choose the right operating model.

    The best model for agent guidance

    In short, the best solution is:

    1. The main instruction defines the agent's role.
    2. The main instruction contains a skills directory.
    3. Each skill describes one task type.
    4. Skills files have a clear structure:
    - when to use
    - goal
    - action steps
    - constraints
    - output format
    5. The main instruction defines what to do if more than one skill is suitable.

    The most important thing is that the agent is not only given multiple skills files, but is also given a clearly expressed selection rule : how the agent recognizes which skill file to use in which situation.

    Last Updated: 3 days ago
    in Artificial Intelligence
    Tags: .md, agent, agent operating model, AI agent, AI-agent, artificial intelligence, instruction text, Markdown, operating instructions, skill, skill instructions, system prompt
    Oliko artikkeli hyödyllinen?

    Related Articles

    • Using AI to support information searching
    • Microsoft 365 Premium Copilot to support teachers in generating verbal feedback
    • Templates for creating agents
    • How to enhance your work with the help of AI
    • AI agents at HAMK

    Footer

    Häme University of Applied Sciences
    (HAMK) / PO Box 230 13101 Hämeenlinna Finland
    03 6461
    HAMK@HAMK.FI

    Privacy policy
    Cookies
    Takedown request
    Accessibility summary
    Site map

    cc-lisenssi

    This material is CC licensed Attribution-ShareAlike 4.0 International.

    Our site uses cookies to track the use of the site and to develop our service. You may decline or accept these cookies.