Discussions on Adding Properties to Types
Start a New Discussion
-
-
Any chance of providing a core property type for attaching arbitrary files? Like you get on most wiki platforms. Are there security issues involved in permitting this? If so, would it be acceptable to limit such a facility to plain-text files?
Robert-
Sure. We could definitely store and display other file formats (in fact we kind of do already) - its just a question of exposing new user interface support for it on Freebase.com. This is a good enhancement suggestion - we will have to think through implications a bit if people start storing large documents that they would like to search through - but some support for basic file upload and display seems very reasonable.
-
I've just done a search in Help for 'attachment' - and the only thing that came up is this question of mine 2 years ago! Any further thoughts on this?
-
I don't think this kind of enhancement is a priority for the folks working on Freebase at this time. Incidentally, I'm no longer one of them (despite the misassigned staff badge). Perhaps Kirrily can comment or put you in touch with someone who can. Cheers.
-
I asked around internally, and the state of things seems to be that our blob database is able to store binary attachments of any kind on the backend via the API, but there are no immediate plans to make this feature available via the website.
What is the use case you have in mind?
And if you just want to attach plain text files, you can currently do so using our API. That's what descriptions are. To connect them to your topic you would need to create schema with a property that expected a document. They would be awkward to view through the website, but accessible via the API.
-
-
-
I am trying to build a Spoiler type. Once associated to a Topic what I really want to do is have the option to have people add the names of properties associated with the Topic to the list of 'spoiler properites'. The ultimate goal would be to make it easy to tell external applications which properties of a topic are 'spoilers' (such as the name of Luke Skywalker's father). Is this possible now? Will this ever be possible?
-
Yes you can, simply specify the type of the property to be 'Property' and make sure that 'Restrict to one value' is unchecked (which it is by default).
However, please keep in mind that as of right now it is not possible to restrict the properties to be properties of of a specific type for e.g. the Film type. As far as the system is concerned it will accept any property of any type. That would make it very easy for users providing the information to mess up.
A simpler, more enforceable and arguably naive model would create a mediator type called spoiler which would connect a film and (for example) a film character. Users could then simply create a spoiler mediator for all characters that have spoiler information related to the film. You could then design any number of spoiler mediators for each type associated with a film/book that contains spoiler information.
HTH -
I see what was confusing me - when I created my new property I was trying to edit the Expected Type during creation. It only lets you set that value AFTER you create it!
I don't exactly follow you idea for the spoiler mediator. Would this just be sort of a flag to say that there is spoiler data? Or would people add the spoiler values to the spoiler mediator for Star Wars/Luke Skywalker? It would be interesting to permit spoilers at the film/book level - but I am not sure I see how people would always be able to add the values they needed to. Can you give me an example so I am sure I understand your idea? -
Think of mediators as a link connecting two or more types (with/without additional data) to model the existence of a relationship between the two without giving it a name.
A couple of e-mails on the developers mailing list are good sources for a description:
http://lists.freebase.com/pipermail/developers/2007-July/000435.html
http://lists.freebase.com/pipermail/developers/2007-July/000437.html
A good example is the film performance type. It links up the file, an actor and a film character with some additional data. It shows up in the film type because it has been linked 'back' in the film type via the performances property.
At the very least what you would need to do if to
1. create a type called film-character-spoiler (or something to that effect)
2. Plead with the film domain admin(s) to allow you to link it up to the Film and Film Character
3. Once you do that, all of a sudden the Film Type and Film Character Type will show up in the Suggested Properties in the fc-spoiler types page, which you can then add as properties to the the fc-spoiler type.
4. Set them up as disambiguators, so that the UI displays them like it does file performances.
5. At this time the UI will not allow you make the properties unique.
6. Yes, its a pain :)
I created an example for you in sandbox:
http://sandbox.freebase.com/view/domain?id=%2Fuser%2Faseem%2Fdefault_domain
Look at the mediator named types. Hurry, these disappear every Monday.
HTH
-
-
-
I created a new type and wanted to give it a Date/Time property named "Timestamp". Turns out I can't save a property with this name. Trying to be clever I named the property "Timestam", made it type Date/Time and successfully saved it but attempted to rename it to "Timestamp" didn't work. I couldn't find a predefined Timestamp type anywhere. Is this a hidden property or keyword or something?
-
Hi, timestamp is a reserved word in Freebase. Properties and Types cannot be named after reserved words. Some other reserved words are: "any", "attribute", "limit", "optional" and all MQL write directives.
-
Thanks. How do I see a list of reserved words? I did a keyword search on "Reserved Words" and, except for the MQL manual, came up dry. - Don
-
The API document on the Developers page has a list of reserved words that's not 100% complete but pretty close: all | any | as | attribute | class connect | count | create | cursor | datatype default | delete | destroy | else | for function | future | if | in | index insert | is | left | limit | link macro | meta | mql | offset | optional pagesize | property | read | relationship | replace return | right | scope | select | self sort | sql | super | this | typeguid update | var | while | write | xml Other reserved words to my knowledge: value, creator, and as you found out, timestamp.
-
-