* Difference between {note} and {inline-note}?

Questions regarding use of any Version of Family Historian. Please ensure you have set your Version of Family Historian in your Profile. If your question fits in one of these subject-specific sub-forums, please ask it there.
avatar
JohnnyCee
Diamond
Posts: 63
Joined: 14 Nov 2016 13:44
Family Historian: V7
Contact:

Difference between {note} and {inline-note}?

Post by JohnnyCee » 09 Nov 2022 16:15

What are the practical differences between {note} and {inline-note}?

FH help says:
Code: {note}

Inserts the note, if any, associated with the relevant fact. Is most suitable for long notes, such as notes which contain one or more whole sentences. The {note} code is normally the last code in the sentence template. If you want the note to appear within its own separate paragraph, you can use <para> formatting codes before and after it, within angle brackets - like this: <<para>{note}<para>>(see How to Add a Prefix or Suffix to any Sentence Template Code below).

Code: {inline-note}

Inserts the note, if any, associated with the relevant fact. Is most suitable for notes which are short, and typically less than a full sentence. The {inline-note} code is typically used for notes which are intended to be inserted as a clause within a sentence.
That recommends when to use the two codes, but not really why, or more importantly, what FH does differently when processing the codes.

User avatar
tatewise
Megastar
Posts: 27078
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Difference between {note} and {inline-note}?

Post by tatewise » 09 Nov 2022 16:28

See the full history and latest changes in ver 7.0.17.1 - spurious full stops (21129).
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry

User avatar
ColeValleyGirl
Megastar
Posts: 4853
Joined: 28 Dec 2005 22:02
Family Historian: V7
Location: Cirencester, Gloucestershire
Contact:

Re: Difference between {note} and {inline-note}?

Post by ColeValleyGirl » 09 Nov 2022 16:39

https://fhug.org.uk/forum/viewtopic.php?t=21129#p129800 summarises the difference I found by experimentation.

avatar
JohnnyCee
Diamond
Posts: 63
Joined: 14 Nov 2016 13:44
Family Historian: V7
Contact:

Re: Difference between {note} and {inline-note}?

Post by JohnnyCee » 09 Nov 2022 17:18

Thank you.

I am curious why there needs to be a difference given a user could put a period and space before a {note} with <. {note}>. I assume there are other issues.

I am more curious about how to handle {inline-note} if the note text includes "rich text" and thus may contain content that must be rendered as a block such as a table, list, etc. GedSite converts FH7 rich text to HTML and I think a complicated and sometimes confusing situation just got worse.

User avatar
tatewise
Megastar
Posts: 27078
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Difference between {note} and {inline-note}?

Post by tatewise » 09 Nov 2022 17:41

John, IMO it is worse than that.
Consider just one type of fact ~ for sake of argument let us choose Census.
What if for some Census facts Note text is a long sentence that needs a full-stop before and after, whereas for other Census facts Note text is a short phrase that does not need any full-stops.
The Census fact Sentence Template needs {note} for the former and {inline-note} for the latter, but there is only one template, so which one should be used?
Maybe it needs something like =TextIf( TextLen(%FACT.NOTE2%) > 50, {note}, {inline-note} )
BUT no you are not allowed codes like {note} inside functions such as =TextIf(...).

Until the full-stop features of {note} were introduced by FH V7, it had worked happily for years with all earlier FH versions.
So why change? That has never been explained.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry

avatar
JohnnyCee
Diamond
Posts: 63
Joined: 14 Nov 2016 13:44
Family Historian: V7
Contact:

Re: Difference between {note} and {inline-note}?

Post by JohnnyCee » 09 Nov 2022 18:33

Mike,

Disclaimer: As you know, I am not a regular user of FH and so my knowledge and recall of FH details is spotty.

With regards to needing/wanting {note} for some text and {inline-note} for others, I thought users could override the sentence template for a particular fact. If so, then I guess the user would choose {note} or {inline-note} for the fact sentence--whichever is the more common requirement--and then override the template for the cases where the other variable is appropriate.

I suspect any automated solution would fail because it's difficult for software to determine when text represents a standalone sentence versus a clause or phrase. It's certainly not decided solely by the length of the text.

It seems we agree that Calico Pie didn't do us any favors by changing the behavior of {note} and then introducing {inline-note} in response to the problem(s) the {note} change raised!

User avatar
tatewise
Megastar
Posts: 27078
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Difference between {note} and {inline-note}?

Post by tatewise » 09 Nov 2022 18:48

You are correct about being able to use specific fact Sentence Templates, but that gets painful if a lot need changing.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry

User avatar
AdrianBruce
Megastar
Posts: 1961
Joined: 09 Aug 2003 21:02
Family Historian: V7
Location: South Cheshire
Contact:

Re: Difference between {note} and {inline-note}?

Post by AdrianBruce » 09 Nov 2022 20:21

JohnnyCee wrote:
09 Nov 2022 17:18
...
I am curious why there needs to be a difference given a user could put a period and space before a {note} with <. {note}>. ...
But in the nicest possible way - why should I, given that I've never had to carry out any special handling like that beforehand?
tatewise wrote:
09 Nov 2022 17:41
...
What if for some Census facts Note text is a long sentence that needs a full-stop before and after, whereas for other Census facts Note text is a short phrase that does not need any full-stops. ...
Sorry Mike - I can't conceive of any way that I wouldn't have the structure of my sentences sorted out beforehand - any full-stop handling simply wouldn't depend on text length for me.
JohnnyCee wrote:
09 Nov 2022 18:33
...
It seems we agree that Calico Pie didn't do us any favors by changing the behavior of {note} and then introducing {inline-note} in response to the problem(s) the {note} change raised!
But I suspect that none of us here were the intended audience and we're not hearing from those people who have (I presume) had their experience improved (as per the original complaint).
Adrian

User avatar
AdrianBruce
Megastar
Posts: 1961
Joined: 09 Aug 2003 21:02
Family Historian: V7
Location: South Cheshire
Contact:

Re: Difference between {note} and {inline-note}?

Post by AdrianBruce » 09 Nov 2022 20:27

JohnnyCee wrote:
09 Nov 2022 18:33
...
I suspect any automated solution would fail because it's difficult for software to determine when text represents a standalone sentence versus a clause or phrase. It's certainly not decided solely by the length of the text. ...
I'd totally agree with you there - it's decided only by the brain of the FH user.

I'd never thought that {note} might represent a clause or phrase that's part of another sentence. It's a full set of sentences as far as I am concerned, that append to the rest of the narrative "sentence". Equally, some people clearly used it as a phrase to insert into the middle of the narrative sentence and presumably never gave the alternative a thought. It's determined by style, not logic. Hence it makes sense to mark up the phrase type usage as clearly different from the appending set of sentences usage.
Adrian

User avatar
tatewise
Megastar
Posts: 27078
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Difference between {note} and {inline-note}?

Post by tatewise » 09 Nov 2022 20:40

But FH must cater for all the alternative possibilities that users may want, whether that is Note sentences or Note phrases.
It is not clear what problems arose with the single {note} code that has served FH users well for many, many years.
The change in the {note} code to introduce full-stops in certain circumstances has never been explained.
I don't believe it has even been mentioned until users started reporting new problems introduced by FH V7.
There was, and still is not, anything in the Help specifically about the insertion of full-stops with the {note} code.
Also, it is not clear whether %FACT.NOTE% is equivalent to {note} or {inline-note}.
The original implementation was also flawed because the Sentence box on the Facts tab was different from what appeared in Narrative Reports.
So now, anyone upgrading from an earlier FH version to FH V7 will probably have to change all their template {note} codes to {inline-note} codes to retain the original behaviour.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry

avatar
JohnnyCee
Diamond
Posts: 63
Joined: 14 Nov 2016 13:44
Family Historian: V7
Contact:

Re: Difference between {note} and {inline-note}?

Post by JohnnyCee » 09 Nov 2022 20:59

AdrianBruce wrote:
09 Nov 2022 20:21
JohnnyCee wrote:
09 Nov 2022 17:18
...
I am curious why there needs to be a difference given a user could put a period and space before a {note} with <. {note}>. ...
But in the nicest possible way - why should I, given that I've never had to carry out any special handling like that beforehand?
I don't understand this comment at all. It's my understanding that {note} in FH6 did not insert a period-space prefix before. Were you not an FH6 user? If FH6 did not have that prefix, why is the prefix somehow necessary now? Somehow FH6 users lived without the prefix before, but adding the prefix manually is now deemed onerous special handling?

Why should people who use {note} have to change to use {inline-note}? They didn't have to do that before. (Let's foist the special handling on them!)

There are circumstances where it really helps if software anticipates issues and solves them. There are many such issues involved in sentence template processing.

Sometimes, however, software goes a little too far and an attempt to be helpful introduces more issues than it solves. I think that's the case here. Before this change, we had "{note}" and "<. {note}>". Now we have "{inline-note}" and "<{note}>", and we retained "<. {inline-note}>", too. (I don't know what happens when someone uses "<. {note}>".) All FH7 users who adjust sentence templates have to be aware of the difference between {note} and {inline-note}, and FH6 users migrating to FH7 have to make changes if they want the old output. There are two ways of doing the same thing, with a little hidden rule associated with one of them.

I know it's not the end of the world, but it does seem like a lot of churn for no benefit.

User avatar
tatewise
Megastar
Posts: 27078
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Difference between {note} and {inline-note}?

Post by tatewise » 10 Nov 2022 11:11

There is also a knock-on consequence for Projects exported to other products that has not been mentioned.
Some products such as GedSite recognise Sentence Template codes and interpret them appropriately.
GedSite would now have to recognise whether the Project was being exported from FH V6 or FH V7 to determine how to interpret the {note} codes correctly. That is just not feasible.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry

avatar
JohnnyCee
Diamond
Posts: 63
Joined: 14 Nov 2016 13:44
Family Historian: V7
Contact:

Re: Difference between {note} and {inline-note}?

Post by JohnnyCee » 10 Nov 2022 12:56

tatewise wrote:
10 Nov 2022 11:11
There is also a knock-on consequence for Projects exported to other products that has not been mentioned.
Some products such as GedSite recognise Sentence Template codes and interpret them appropriately.
GedSite would now have to recognise whether the Project was being exported from FH V6 or FH V7 to determine how to interpret the {note} codes correctly. That is just not feasible.
Actually, Mike, the GedSite beta testers have access to a version that does precisely what you described: {note} acts one way for GEDCOM files exported from FH6 and a different way for GEDCOM files exported from FH7. The beta version also includes support for {inline-note}.

I expect to release the GedSite update within a few days.

User avatar
tatewise
Megastar
Posts: 27078
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Difference between {note} and {inline-note}?

Post by tatewise » 10 Nov 2022 13:30

OK, but you presumably had to jump through hoops to cope with the FH V7 changes as they are not backwards compatible.
Other product developers may not be so accommodating.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry

User avatar
Robert Jacobs
Famous
Posts: 111
Joined: 21 Mar 2015 18:03
Family Historian: V7
Location: Ellensburg, Washington, U.S.A.
Contact:

Re: Difference between {note} and {inline-note}?

Post by Robert Jacobs » 10 Nov 2022 13:56

The fix for Calico Pie's alteration of the {note} code is a global find and replace: <{note}> in place of <. {note}>. The underlying sentence templates can be changed en masse using Notepad on the .fhf files in C:\ProgramData\Calico Pie\Family Historian\Fact Types.

I have done this for my project (not without considerable trepidation and multiple carefully labelled backups) and all seems well.

NB -- this procedure does NOT consider the needs of the upgrader from FH6. I dealt with FH7 only.

avatar
JohnnyCee
Diamond
Posts: 63
Joined: 14 Nov 2016 13:44
Family Historian: V7
Contact:

Re: Difference between {note} and {inline-note}?

Post by JohnnyCee » 10 Nov 2022 17:03

tatewise wrote:
10 Nov 2022 13:30
OK, but you presumably had to jump through hoops to cope with the FH V7 changes as they are not backwards compatible.
Other product developers may not be so accommodating.
Yeah, this sort of thing is definitely a hassle. In this specific case, the actual changes were minimal, but deciding what to change took some time to work out. Then there's testing, documenting, explaining to beta testers, etc.

GedSite has easy access to the major version of the software that wrote the GEDCOM file if the GEDCOM file supplies it. In this case, I modified an FH-specific method in GedSite that processed _SENT records. I added a case-blind replace changing "{note}" to "{inline-note}" when majorVersion is less than 7.

Also, I adjusted an internal "variable map" to account for the new/changed {note} and {inline-note}:

Code: Select all

         AddVariableMapInfo(map, new VariableMapInfo("note", "M:Note:PF:. "));
         AddVariableMapInfo(map, new VariableMapInfo("inline-note", "M:Note"));
Given the modification to the sentences for FH6 and prior, it's OK for {note} to always include the prefix while {inline-note} does not because FH6 and prior use {note} but that is changed to {inline-note} before the templates are interpreted.

There's nothing here anyone needs to know, just providing a blog-ish response to demonstrate the ripple effects of the change in a third-party tool.

User avatar
AdrianBruce
Megastar
Posts: 1961
Joined: 09 Aug 2003 21:02
Family Historian: V7
Location: South Cheshire
Contact:

Re: Difference between {note} and {inline-note}?

Post by AdrianBruce » 10 Nov 2022 17:11

JohnnyCee wrote:
09 Nov 2022 20:59
AdrianBruce wrote:
09 Nov 2022 20:21
JohnnyCee wrote:
09 Nov 2022 17:18
...
I am curious why there needs to be a difference given a user could put a period and space before a {note} with <. {note}>. ...
But in the nicest possible way - why should I, given that I've never had to carry out any special handling like that beforehand?
I don't understand this comment at all. It's my understanding that {note} in FH6 did not insert a period-space prefix before. Were you not an FH6 user? ...
At the risk of making me sound like "well I didn't have a problem", because obviously there are issues for some people, but to explain my own words, I can only repeat that I never used
<. {note}>.
in either v6 or v7. I would always process the period at the end of the previous set of angle brackets and then use {note}. So far as I know, I never had any problem. (That's a big caveat, of course, given the size of reports.) Certainly I used leading space between angle bracket, e.g.
< {thing}>
(That leading space is now no longer necessary as FH attempts to control spaces - another reason for me to say that there are multi-passes.). Perhaps my v.7 constructions never hit the necessity to invoke period space period etc.
Adrian

User avatar
AdrianBruce
Megastar
Posts: 1961
Joined: 09 Aug 2003 21:02
Family Historian: V7
Location: South Cheshire
Contact:

Re: Difference between {note} and {inline-note}?

Post by AdrianBruce » 10 Nov 2022 17:14

tatewise wrote:
09 Nov 2022 20:40
... It is not clear what problems arose with the single {note} code that has served FH users well for many, many years.
The change in the {note} code to introduce full-stops in certain circumstances has never been explained. ...
Being pedantic about it, because there was no explanation, we can't actually say that there was a change in the {note} related software. Given the multiple layers and multi-pass processing that appears to go on, it is not impossible that the change was to something different and {note} was the innocent victim.
tatewise wrote:
09 Nov 2022 20:40
The original implementation was also flawed because the Sentence box on the Facts tab was different from what appeared in Narrative Reports.
But the sentence box has always been different - it seems to use pronouns for the principal, whereas the Narrative Report mixes pronouns and proper names in a manner depending on the rest of the narrative - which is one reason why I contend there is layered / multi-pass logic

tatewise wrote:
09 Nov 2022 20:40
So now, anyone upgrading from an earlier FH version to FH V7 will probably have to change all their template {note} codes to {inline-note} codes to retain the original behaviour.
I think "anyone" is an exaggeration. Anyone upgrading who uses their notes as phrases, yes. But not anyone who uses their notes as sentences.
Adrian

User avatar
tatewise
Megastar
Posts: 27078
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Difference between {note} and {inline-note}?

Post by tatewise » 10 Nov 2022 17:28

AdrianBruce wrote:
10 Nov 2022 17:14
tatewise wrote:
09 Nov 2022 20:40
The original implementation was also flawed because the Sentence box on the Facts tab was different from what appeared in Narrative Reports.
But the sentence box has always been different - it seems to use pronouns for the principal, whereas the Narrative Report mixes pronouns and proper names in a manner depending on the rest of the narrative - which is one reason why I contend there is layered / multi-pass logic
I know the names/pronouns differ. I was referring to the bug that displayed the punctuation and spaces around {note} differently and has now been fixed. It was discussed at length in the forums but cannot find it now.
AdrianBruce wrote:
10 Nov 2022 17:14
tatewise wrote:
09 Nov 2022 20:40
So now, anyone upgrading from an earlier FH version to FH V7 will probably have to change all their template {note} codes to {inline-note} codes to retain the original behaviour.
I think "anyone" is an exaggeration. Anyone upgrading who uses their notes as phrases, yes. But not anyone who uses their notes as sentences.
I suspect even some who used {note} as sentences may need to change the punctuation they have in templates.
For example change <. {note}> to just {note}. Who knows since the change is not well documented.

The fact there has been so mich discussion about various options and formats leads me to suspect the story has not ended yet
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry

User avatar
AdrianBruce
Megastar
Posts: 1961
Joined: 09 Aug 2003 21:02
Family Historian: V7
Location: South Cheshire
Contact:

Re: Difference between {note} and {inline-note}?

Post by AdrianBruce » 10 Nov 2022 23:05

tatewise wrote:
10 Nov 2022 17:28
... I was referring to the bug that displayed the punctuation and spaces around {note} differently and has now been fixed. It was discussed at length in the forums but cannot find it now. ...
Strangely I couldn't find that thread either and nor could Helen - assuming that we're talking about the same thread.

What I did find in my own correspondence was an issue with narrative sentences where the sentence shown on the Fact tab was constructed correctly, whereas by the time it was in the narrative report, it wasn't. This was in June 2021 and I'd raised a call with CP. It may be another instance similar to the punctuation and spaces around {note} - if it is, then that's why I think {note} may have been an innocent victim of an issue elsewhere.

What had happened was that I had a narrative sentence

Code: Select all

<para>{individual} lived< at {address}>< {place}>< with {other=resident}>< {date}>.
Notice that I was explicitly handling all the spaces within angle brackets, as we had to do at one time to avoid multiple spare spaces if items were empty. Or at least, I'm certain in my own mind that we did.

That displayed fine in the sentence shown on the Fact tab, whereas by the time it was in the narrative report, it didn't. The mails have a title of Missing Space in Narrative Report for Residence, which may indicate the issue. (As an aside, this is why I said "the sentence box has always been different" - though "always" may be an exaggeration).

What Martin (from CP) said was (inter alia):
The reason the space problem happens is that you are trying to manage spaces between expressions in the sentence template. Family Historian expects to handle this for you. Consequently there is a tension between what you are trying to do and what Family Historian is trying to do.
His recommendation was the simpler

Code: Select all

<para>{individual} lived <at {address}> {place} <with {other=resident}> {date}.
This excludes spaces inside angle brackets and it works but I've not converted other narrative sentences unless I've been working in them and I've not noticed any other issues (i.e. there may be other spacing issues that I've not picked up on).

To summarise:
1. This illustrates another difference between the sentence in the Fact tab and that in the Narrative Report.
2. It also suggests to me that there is complex post-processing done after the basic construction of the Narrative sentence in the Report, i.e. {note} issues may just have been side effects, rather than an explicit change to {note} processing. Maybe.
tatewise wrote:
10 Nov 2022 17:28
... The fact there has been so mich discussion about various options and formats leads me to suspect the story has not ended yet
That I would agree with...
Adrian

User avatar
tatewise
Megastar
Posts: 27078
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Difference between {note} and {inline-note}?

Post by tatewise » 11 Nov 2022 10:12

I have now found three threads that discussed the {note} sentence display problems in Reports:
Fact definitions & unwanted carriage returns (19695) Aug 2021
Sentence different from property box & report (20016) Nov 2021
Fact sentence structure - output error (20389) Mar 2022
I'm sure there were more, possibly in the group.io mailings.
They all seem to be due to the undocumented change in the {note} concepts in FH V7.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry

User avatar
NickWalker
Megastar
Posts: 2401
Joined: 02 Jan 2004 17:39
Family Historian: V7
Location: Lancashire, UK
Contact:

Re: Difference between {note} and {inline-note}?

Post by NickWalker » 11 Nov 2022 10:24

tatewise wrote:
11 Nov 2022 10:12
I'm sure there were more, possibly in the group.io mailings.
I have a feeling there was a discussion about this when we were beta testing FH7 back in 2020 so perhaps the conversations you are remembering were in the forum that we had access to then.
Nick Walker
Ancestral Sources Developer

https://fhug.org.uk/kb/kb-article/ancestral-sources/

User avatar
tatewise
Megastar
Posts: 27078
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Difference between {note} and {inline-note}?

Post by tatewise » 11 Nov 2022 10:31

If so, then CP were getting warnings about the change to {note} very early on and should have reversed the changes then.
Postponing the changes has led to this contentious problem.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry

User avatar
ColeValleyGirl
Megastar
Posts: 4853
Joined: 28 Dec 2005 22:02
Family Historian: V7
Location: Cirencester, Gloucestershire
Contact:

Re: Difference between {note} and {inline-note}?

Post by ColeValleyGirl » 11 Nov 2022 10:34

Mike, there are definitely more than that -- there's one quite recently where I and Adrian B said that we understood a note to be one or more complete sentences (based on the normal English use of the word) and not a sentence fragment, so we could understand why the changes in V7 for {note} made sense... But it seems to be a magic disappearing topic!

User avatar
LornaCraig
Megastar
Posts: 2989
Joined: 11 Jan 2005 17:36
Family Historian: V7
Location: Oxfordshire, UK

Re: Difference between {note} and {inline-note}?

Post by LornaCraig » 11 Nov 2022 10:51

Yes, I remember that discussion too, and have searched for it in vain.
Lorna

Post Reply