<commit_before>+++
title = "7. Structures and Marks"
weight = 35
template = "doc.html"
+++

Before we get into subscription mechanics, there's three things we need to touch
on that are very commonly used in Gall agents. The first is defining an agent's
types in a `/sur` structure file, the second is `mark` files, and the third is
permissions.

## `/sur`

In the [previous lesson on pokes](/docs/userspace/gall-guide/6-pokes), we used a
very simple union in the `vase` for incoming pokes:

```hoon<commit_msg>gall-guide: lesson 7 - add note that the code won't build a proper agent<commit_after>+++
title = "7. Structures and Marks"
weight = 35
template = "doc.html"
+++

Before we get into subscription mechanics, there's three things we need to touch
on that are very commonly used in Gall agents. The first is defining an agent's
types in a `/sur` structure file, the second is `mark` files, and the third is
permissions. Note the example code presented in this lesson will not yet build a
fully functioning Gall agent, we'll get to that in the next lesson.

## `/sur`

In the [previous lesson on pokes](/docs/userspace/gall-guide/6-pokes), we used a
very simple union in the `vase` for incoming pokes:

```hoon
{'fraction_non_alphanumeric': 0.09135802469135802, 'fraction_numerical': 0.007407407407407408, 'mean_word_length': 4.28695652173913, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3950026', 'n_tokens_mistral': 376, 'n_tokens_neox': 354, 'n_words': 184}