yyGrams logoyyGrams/tweet formats

Formats for yyGrams™ the troubleshooting puzzles™ and yyRaptor online game

Motivation . Puzzle . Format . Models . Answer . Pool . App Notes

Motivation

1.a Format layout is for avoiding miscommunication. When you want to interact with a play co-ordinating group or a software engine, formatting will be important at some level, perhaps handled beneath the correspondents' notice within an app.

Puzzle

A yyGrams™ puzzle consists of

1.b ID, author-date-time-nr — helps identify the puzzle for discussion. Format is left to the correspondents. -nr- is a serial number, unique to the day, month or year, your choice.

1.c pool specification, optional.

1.d there-lists — set-bracket pairs {..} enclosing names to be substituted into the (hidden) yygram. Names are single-letter always.

1.e You show valuation outcomes for all there-lists in a puzzle. The format calls for presenting them in two outcome lists. The tag for the yiN list is <n: > and for the yang list, <y: >.

top

Format proper

2.f The format proper is between opening and closing:
<#yypuz 5> .... </yy> for puzzles, and between
<#yygram 5> ... </yy> for answers.

2.g In a tweet, all before an opening and after a closing is optional. It is not required that a tweet begin with a format opening.

2.h Sequence of items other than the opening and closing tags is not fixed. The tagged enclosures for outcome-lists may appear in either order: <y: ..><n: ..>, or <n: ..><y: ..>

2.i In puzzle format, separating names with commas is optional, since names are one-letter always. A larger puzzle might have a there-list such as {rtz}{rt}{hrp}{hpz}{pz}{pt}. Set-brackets are required. (Set-brackets and parentheses may look confusingly similar in some fonts in small size.)

2.j In a yy-gram it is not strictly proper to include commas, since native zang-fu notation knows no punctuation other than paired encloser marks. App engines are to ignore commas that appear within a yy-gram.

3.a Whitespace is optional except between the initial tag and the format revision—here, <#yypuz 5> or <#yygram 5>

3.b Semicolons modeled are not optional.

3.c Further app programming notes appear further on.

top

Models



4.a A puzzle might tweet like this:

<#yypuz 5><n: { }{h}{h,j}><y: {j}>#auth 12f45</yy>

4.b Those there-lists that evaluate to Yang (the "Yang column") might appear before or after those that evaluate to yiN:

<#yypuz 5><y: {j}> <n: { }{h}{h,j}>#auth 12f45</yy>

top

Answer yy-gram



5.a A yyGram—a puzzle answer—from an author might tweet like this:

<#yygram 5>#auth<!ans: ((j)h)>12f45</yy>

5.b A first answer from a correspondent:

<#yygram 5><?ans1: (h(j))>#auth 12f45</yy>

5.c The two yy-grams are equivalent, so now the author might reply:

5.d <#yygram 5><!ans1: (h(j))>#auth 12f45</yy>

top


"Pool" format with alphabet and range:

6.a <#yypuz 5><r,h,p 2-3><n: {hp}{h}> <y:*>auth 12f41</yy>


"Pool" format with alphabet alone:

6.b <#yypuz 5><kgm><y: {gk}{g}{hk}{mg}{mkg}{ }> <n:*>#auth 12fa5</yy>


"Pool" format with range alone:

6.c <#yypuz 5><1-3><y: {gk}{g}{hk}{mg}{mkg}{ }> <n:*>#auth 12fa5</yy>

top

Live and Bogus Names

7.a In "pool" format, an "alphabet" gives the pool of names that may be "live" in the puzzle. Not all the names in the pool have to make a difference in the outcomes—to be live, that is. In a harder puzzle some of the names may be bogus.

7.b A range tells how many names from the pool may be live.

7.c When a range is not given, the intended range is from zero to the count of unique names in the outcome lists.

7.d A somewhat easier puzzle happens when a smaller live range is given, perhaps even just a single number, such as <r,h,p 2>.

8.a A range that includes zero says that the answer yy-gram may be a degenerate or "stuck simple" function—forever returning yiN only or Yang only on evaluation. In puzzles, such will be immediately obvious. In the yyRaptor game, however, it is a live possibility.

8.b When a pool alphabet of names is specified, one of the outcome-lists may be omitted, with its tagged enclosure. Alternatively, for clarity, the usual enclosure for one of the lists may contain an asterisk, *, to signify "all other valuations".

8.c The "all other there-lists" outcome list shown as <y:*> in the model format here may be omitted if you are sure your correspondents are sufficiently advanced.

8.d An example answer, second one from a correspondent, is:

8.e <#yygram 5>auth<?ans2:(h) r>12f41</yy>

8.f An example answer, from the author, is:

<#yygram 5><!ans:r (h)>auth 12f41</yy>

8.g The "ans" tag is legal so long as the substring "ans" appears somewhere between the opening angle-bracket and the next colon. Punctuation and numerals may precede and follow, to distinguish originator and intentionally different yy-gram forms ad libitum.

top




App Programming Notes

ID Uniqueness

9.a Uniqueness cannot be absolute over all namespaces but can be attempted in some particular namespace. This motivates the programming notes here.

Care in storing ID

9.b To prevent unintential aliasing of ID's when many puzzles are to be handled on a database, care is required.

9.c Content outside paired < .. > marks is all considered part of ID.

9.d If < .. > tag-container pairs intervene, the ID is considered to be not simply the concatenation of un-enclosed characters. An app engine is not to display the ID as one serial string but rather piecewise, storing pieces padded with a single space in place of the tagging that may separate pieces in the received stream.

9.e An empty tag-enclosure pair <> is to have the same force in this regard as other tags, counting as a single space for storage and lookup.

9.f Whitespace within such a piece is to be condensed to a single space character, as is the default parsing in XML/HTML.

9.g Given the meaningfulnes in Twitter context of the # sign signaling a hashtag, this sign shall be omitted for storage and lookup. This allows for manual preparation of puzzles and answers to be hashtag-inconsistent without penalty.

top


dz@yyGrams.com

©2012 David Zethmayr
2012.4.8 = 12g8 — 15:00J