X-Logic is a document oriented logical framework for the semantic web.
At the X-Logic level we are concerned with documents as assertions, and with programs performing inferences by reading documents
and creating new documents.

The key surprises here are:

The languages which concern us here are not just logics, but any language which has a propositional semantics, and any language can be given a propositional semantics (or two).

The things which do inference are not just theorem provers, but any program which has a propositional specification, and any program can be given a propositional specification (or two).

The Theory xl-mm1

We here introduce the new theory in the context of galactic set theory (though it could have been done in less exotic environs).

This is just the first stage in the development of models for XL-Glue, and doesn't yield a good model.
I had hoped that it would be useful for the exposition of the "two key ideas", but even for that purpose it would need to
be reworked substantially.
The second metamodel seems to me better, but because it is intended to address the use of digital signatures it is also significantly
more complex.
Someday this will have to be redone.

Types

An overview of the model with specifications of the various types of entity involved in it.

Domain of Discourse

The subject matter of the model is programs which perform transformations over documents, which are written in a variety of
languages.

We take the set of documents to be unspecified.
A language is modelled as a set of documents.

This should be understood as a purely semantic definition, in which the essential feature of a document is that it expresses an assertion, and the only matter of interest
for our present purposes is whether that assertion is true.

Thus the set of documents which constitutes a language is the set of documents which when interpreted in that language are
true.

A program is any partial function over the documents.
A specification is any pair of languages, which are to be understood as the input and output languages of some program.

Basic Types

The following definition should be understood as introducing the semantic objects which correspond to the parts of a very
simple language.
Of these, the last three are kinds of "proposition" corresponding two three kinds of sentence which are available in our language.
Informally they are the propositions respectively that a document in some language is true, that a program satisfies some
specification, and that one document has been computed from another by some program.

Three kinds of proposition are defined, concerning truth of documents, correctness of programs and derivation of documents.

In this section we provide the meaning for the three kinds of proposition introduced above. In each case this is a property
which should be understood as defining when the relevant kind of sentence is true.

Truth

First, a document is true in some language if it is a member of that language.
(it suffices for our present purposes to model a language by its set of true sentences)

xl-holconst

TrueDocP: GS → BOOL

∀dp• TrueDocP dp ≡ dp ∈g DocProp ∧ (dp_doc dp) ∈g (dp_lang dp)

Inference

Next, some document is inferred by a program from another document if the function which is the value of the program maps
the second document to the first.
Note that function application is not used in this statement because of the possible complication that the input document
is not in the domain of the function.

This is not the kind of reasoning which the metanotation is intended for, but as a very trivial demonstation of how programs
other than proof tools can do inferences for us we demonstrate that the identity function infers soundly against any specification
in which the input and output languages are the same.
(i.e. given a true proposition it returns the same true proposition)

In the following theorem the ⌜l ↦g l⌝ is the specification, which states that the input and output languages are both ⌜l⌝, and the right hand side of the conditional
asserts that the identity function over ⌜l⌝ satisfies that specification or is sound with respect to that specification.
i.e. when given a true proposition in language ⌜l⌝, it returns a true proposition in the same language.
The specification does not require the output proposition to be the same as the input proposition, but in this case it is.

In the following we investigate the kind of reasoning which could be undertaken in a language suitable for talking about the
model we have introduced.
Rather than invent a language, we use the syntax already available to us, and build up some elementary tools for reasoning
about the model.
If we then devised a suitable special concrete syntax and gave this its semantics in terms of the model by a semantic embedding
into ProofPower GST, the proof tools we devise here would then serve as a tools for reasoning about this new language.
The step to concrete syntax will be omitted, however, since we expect further elaborations to the model before this would
be worthwhile.

What kind of logic?

We have a language in which programs, modelled as functions, are applied to documents to yield new documents, and hence an
expression language involving function application.
We have a couple of predicates which are applied to these programs and documents.
So it looks like we are heading for some kind of predicate calculus.

On the other hand, if we consider languages as types of document and specifications as types of program, then both our predicates
become typing assertions in an applicative calculus.
Since typing inference in pure combinatory logic is the same as a fragment of propositional logic we may hope that a metalanguage
based on the simple model we have in hand will logically much simpler than the predicate calculus, and we may hope for fully
automatic proofs.

Because programs are permitted only one input and one output document, the limitations of this metamodel are very severe.
Now we have modus ponens we can easily compose inferences to give results over chains of computations, but that's about all
we can do.