CVS edit link for alex.klebeck
Ontos Feeder automatically analyzes the content of your article and provides additional information for the main topics. In addition it allows to automatically create and embed relevant metadata into your published text. Currently supported formats are RDFa and Microformats.Ontos Feeder uses Ontos' Semantic API in order to process your text with cutting-edge NLP technology, and the [Ontos News Portal](http://news.ontos.com) as one of the sources for additional relevant information. In order to be able to use the plug-in, you have to subscribe for an API account at [Ontos](http://www.ontos.com), tab 'Semantic API'.
After successful installation you see a button 'Get tags!' in your WYSIWYG editor. Write some text and press this button. Ontos Feeder will automatically find the main topics of your article, mark them in the text and provide additinal information in the separate Ontos Feeder frame. Check these information by clicking on the marked text or an entry in the Ontos Feeder frame. If you asked for automatically creating RDFa or Microformats for your content, you may delete the marks that you don't want to appear in your published article directly in the editor.
| Comment | File | Size | Author |
|---|---|---|---|
| #14 | ontos_feeder 4 drupal release 1.0.3.zip | 9.37 KB | alex.klebeck |
| #11 | ontos_feeder 4 drupal release 1.0.2.zip | 8.91 KB | alex.klebeck |
| #9 | ontosFeeder-drupal release 1.0.1.zip | 22 KB | alex.klebeck |
| #1 | ontosFeeder-drupal release 1.0.zip | 614.95 KB | alex.klebeck |
Comments
Comment #1
alex.klebeck commentedplease review the attached Ontos Feeder module. Thank you :)
Comment #2
avpadernoHello, and thanks for applying for a CVS account. I am adding the review tags, and some volunteers will review the code, pointing out what it needs to be changed.
As per requirements, the motivation message should be expanded to contain more features of the proposed project. For themes, it should include also a screenshot of the theme, and (when possible) a link to a working demo site; for modules, it should include also a comparison with the existing solutions.
Comment #3
alex.klebeck commentedHello kiamlaluno! Thank you very much for your hints. Below is a more expressive description of our plug-in together with some installation instructions (if already needed in this step). Please have a look at it!
What is it?
Ontos Feeder is a plug-in for content management systems focussing on online content providers. Its main goals are to
- support the editor during the authoring process with meaningfule and relevant information (recommendations): What is mentioned in other sources about the article's subject? Show additional sites as e. g. Social Network pages or homepages for the main topics. What kind of additional information are availabe in the web (especially the Linked Data community)?
- enhance the article's quality by automatically embedding metadata (RDFa or Microformats) for the main topics: Improve the quality of search results; allow data integrators to use the content and automatically link it to other points of the web.
Ontos Feeder uses Ontos' Semantic API in order to automatically process your text with cutting-edge NLP technology, and the [Ontos News Portal](http://news.ontos.com) as one of the sources for additional relevant information. In order to be able to use the plug-in, you have to subscribe for an API account at [Ontos](http://www.ontos.com), tab 'Semantic API'.
After successful installation you see a button 'Get tags!' in your WYSIWYG editor. Write some text and press this button. Ontos Feeder will automatically find the main topics of your article, mark them in the text and provide additinal information in the separate Ontos Feeder frame. Check these information by clicking on the marked text or an entry in the Ontos Feeder frame. If you asked for automatically creating RDFa or Microformats for your content, you may delete the marks that you don't want to appear in your published article directly in the editor.
The main advantage compared to other CMS plug-ins that provide RDFa embedding is that Ontos Feeder creates the metadata fully automatically without any manual interaction. The respective information come from sources as the already mentioned Ontos News Portal, but also from the big players in the Linked Data community: DBpedia and Freebase.
Installation
1. Copy the directory 'ontosFeeder' to the '/sites/all/modules/' directory of your Drupal installation.
1. Activate the plug-in through the 'Administer | Site building | Modules' menu in Drupal.
1. Add 'Ontos Feeder' to the right sidebar in the 'Administer | Site building | Blocks' menu in Drupal.
1. Apply for an API account at [Ontos](http://www.ontos.com/o_eng/index.php?cs=2-3 "Semantic API"). You will receive an e-mail with your personal user name and password.
1. Select 'Ontos Settings' in the 'Administer | Site configuration' menu in Drupal.
1.1 Enter your user name and password,
1.1 Select what kind of metadata you want to automatically get injected into your content,
1.1 Select what kind of objects you are interested in,
1.1 Save your settings.
The FCKeditor is required for this module to function.
Credits
This project is sponsored by [Ontos AG](http://www.ontos.com).
Comment #4
avpadernoThank you for your reply.
Comment #5
scor commentedWhat's the exact license? I see LGPL in miner.php for example. LoggerAppenderPool.php contains an ASF license. Drupal modules hosted on drupal.org are released as GPL 2.
Also, if the module contains external libraries, these should not be part of the module on CVS, but rather downloaded by the user when installing the module.
Comment #6
avpadernoI am changing status as per previous comment.
When you apply for a CVS account, you agree to commit only code that is licensed under GPL License.
scor is right on what he reports.
Comment #7
alex.klebeck commentedhello kiamlaluno
hello scor,
actually our plugin currently depends on plenty of external libriaries, such as log4php, log4javascript, jquery, jqueryUI, jquery Fancy Box, jquery MouseWheel, jquery wait, a template for a popup menu , a sparql libriary.
should the user be really forced to download all of them separately and put them into correct folders of our plug-in? Wouldn't this be an overkill for a "dummy" user? :)
Thank you!
Comment #8
avpadernoYes.
Comment #9
alex.klebeck commentedwe adapted our module and moved to the GPLv2. Also all external libriaries where removed. Please review :)
Comment #10
avpadernoRemove any reference to the license inside files.
The copyright statement would not correct from the moment you accept a patch from any users; to make an example; Drupal is not copyrighted by Dries Buytaert, but from all the contributors.
t().There is a Drupal function to call in those cases.
Such files have an extension .inc, in Drupal.
It usually not a good idea to unconditionally include code contained in PHP files. If the files contain form handlers, theme functions, or menu callbacks, Drupal core code allows to third-party modules to define which files must be loaded in the implementations of
hook_menu(), andhook_theme(); in these cases, Drupal loads the file only when necessary.The CVS ID tag is placed at the top of the file, after
<?php, in a PHP file.Please update the comment for the proposed module; that comment is just the copy of the comment present in another module.
The description is copied from another module. The code implemented for
hook_filter()doesn't actually do anything, not even what reported in the description.I don't see the reason for
hook_menu()to call another function that just returns the array thathook_menu()could have directly returned.There is a form submission callback, but I don't see any form using it.
The implementation of
hook_block()is not checking the first parameter, and it returns always the same value.As reported in Documenting hook implementations:
Comment #11
alex.klebeck commentedHello kiamlaluno,
thank you very much for your review. I submit the changed module as follows:
1. licence comments removed
2. licence file removed
3. I don't really understand, where putting the t() function would be appropriate or not. All occurences in the code are taken from the official api pages (like http://api.drupal.org/api/function/hook_block), where the t() is widely used. I've removed some t()'s, please check if it is ok so.
4. The files in "core" are not part of the Ontos Feeder module, but must be downloaded separately from the Ontos Website. Since the "core" is cross-CMS, the file naming there shouldn't be subject to the Drupal's code convetions.
5. The API Documentation for "hook_menu" states, that it is called rarely (on module activation). On the other side, the files need to be included on every page request.
6. Wrong comment removed.
7. hook_filter removed
8. Checked the code with the "coder" module and applied the Drupal coding standards.
9. The code has a well-defined structure. All code related to the options page is put together in the ota_options.php. The ontos_feeder_menu() in the ontos_feeder.module file delegates to the appropriate code as neccessary.
10. This callback is used by the "Ontos Settings" configuration form, that is defined in the function "ota_form_submit" in the ota_options.php.
11. The parameter is checked within $blocks->show($op, $delta);
12. Hook comments added
Comment #12
avpadernoPoints #4, #5, and #8 are still valid.
Points #4 is still valid for the Drupal function to use in such cases; point #8 is still valid for the names to give to the functions.
Comment #14
alex.klebeck commentedI've changed the function names and used module_load_includes instead of require_once. Please review
Comment #15
alex.klebeck commentedHello kiamlaluno,
we are waiting to proceed with the module publishing, can you please tell me if you still need much time to review my last submission?
Thank you!
Comment #16
alex.klebeck commentedHello,
I can see the "CVS edit link for alex.klebeck" on top of this issue page now, but after clicking on it the page says that I am not authorized to access it. Am I missing something?
Sincerely
Comment #17
alex.klebeck commentedComment #18
avpadernoComment #19
zzolo commented@alex.klebeck, thanks for the application and patience. The following points are just a start and do not necessarily encompass all of the changes that may be necessary for your approval. Also, a specific point may just be an example and may apply in other places.
Overall, you do not seem to utilize the Drupal API correctly. Please read up on the coding standards, writing secure code, and other documentation linked below as to how to be writing efficient, secure code that will be beneficial to the community. We really appreciate your drive and contributions, but this still needs a fair amount of work, IMO.
In is often very confusing for users to put specific files where you expect them. This is mostly cause by the fact that "extract" is relative to how things are packaged and what program is used. I would suggest you expand this to be much more detailed.
You do not have a docblock for the function. There is really no need to put the schema in a different file and function; this is why there is an install file in the first place. Also, there is no reason to use module_invoke unless you think other modules should be messing with your schema (which they should not).
You NEED to sanitize values in the DB query, and can do this easily by using the Drupal API correctly. Please see db_query()
You should not use a different prefix (OTA) here. Namespacing and prefixing is extremely important in Drupal. You are assuming http (when someone could be using https). You should be utilizing url() and the absolute option.
These need to be translatable using t(). Also, I am not sure why these are constants in the first place.
There should be little need to use a global variable like this. You could utilize a static variable or use the global variable within functions to achieve the same thing probably.
You do not need to utilize module_invoke, just call your function directly. You are also not including the file that this function is in.
This needs to be translatable. Also, this should not be displayed to most users, so I would suggest you log this with watchdog().
I don't understand why you are altering your own form?
Don't need module_invoke(). There doesn't seem to be any apparent reason to keep
You are not utilizing drupal_add_js correctly. Also, you are including almost 50 JS files which is horrible for performance. Your "OTA core" that is downloaded should include a compressed version of all this if it is really needed. Also, you are including a different version of jQuery than core which will probably conflict as they are both included.
--
Note: Please be patient with the CVS application process. It is all done by volunteers. Our goal is not to be arbitrarily slow or meticulous. Our goal is to get you CVS access and ensure that you are and will become a more responsible Drupal contributor. For a quick reference on what I look for in a code review, please see this article, or read the handbook page on how to review for reference..
Comment #20
avpadernoTo add a note to what reported by zzolo, code like the following is not correct too, basing on what reported in the documentation for
t():Comment #21
avpadernoIs there any updates on this?
Comment #22
avpadernoPlease read all the following and the links provided as this is very important information about your CVS Application.
Drupal.org has moved from CVS to Git! This is a very significant change for the Drupal community and for your application. Please read the following documentation on how this affects and benefits you and the application process:Migrating from CVS Applications to (Git) Full Project Applications.