Re: [Wikitech-l] [Engineering] Wikimedia REST content API is now available in beta
Congratulations! After all the hard work that has gone into this, it's great to see it up and running. Besides the improvements it will allow in existing projects, I can't wait to see the new things it will enable. -- Marc On Tue, Mar 10, 2015 at 11:23 PM, Gabriel Wicke gwi...@wikimedia.org wrote: Hello all, I am happy to announce the beta release of the Wikimedia REST Content API at https://rest.wikimedia.org/ Each domain has its own API documentation, which is auto-generated from Swagger API specs. For example, here is the link for the English Wikipedia: https://rest.wikimedia.org/en.wikipedia.org/v1/?doc At present, this API provides convenient and low-latency access to article HTML, page metadata and content conversions between HTML and wikitext. After extensive testing we are confident that these endpoints are ready for production use, but have marked them as 'unstable' until we have also validated this with production users. You can start writing applications that depend on it now, if you aren't afraid of possible minor changes before transitioning to 'stable' status. For the definition of the terms ‘stable’ and ‘unstable’ see https://www.mediawiki.org/wiki/API_versioning . While general and not specific to VisualEditor, the selection of endpoints reflects this release's focus on speeding up VisualEditor. By storing private Parsoid round-trip information separately, we were able to reduce the HTML size by about 40%. This in turn reduces network transfer and processing times, which will make loading and saving with VisualEditor faster. We are also switching from a cache to actual storage, which will eliminate slow VisualEditor loads caused by cache misses. Other users of Parsoid HTML like Flow, HTML dumps, the OCG PDF renderer or Content translation will benefit similarly. But, we are not done yet. In the medium term, we plan to further reduce the HTML size by separating out all read-write metadata. This should allow us to use Parsoid HTML with its semantic markup https://www.mediawiki.org/wiki/Parsoid/MediaWiki_DOM_spec directly for both views and editing without increasing the HTML size over the current output. Combined with performance work in VisualEditor, this has the potential to make switching to visual editing instantaneous and free of any scrolling. We are also investigating a sub-page-level edit API for micro-contributions and very fast VisualEditor saves. HTML saves don't necessarily have to wait for the page to re-render from wikitext, which means that we can potentially make them faster than wikitext saves. For this to work we'll need to minimize network transfer and processing time on both client and server. More generally, this API is intended to be the beginning of a multi-purpose content API. Its implementation (RESTBase http://www.mediawiki.org/wiki/RESTBase) is driven by a declarative Swagger API specification, which helps to make it straightforward to extend the API with new entry points. The same API spec is also used to auto-generate the aforementioned sandbox environment, complete with handy try it buttons. So, please give it a try and let us know what you think! This API is currently unmetered; we recommend that users not perform more than 200 requests per second and may implement limitations if necessary. I also want to use this opportunity to thank all contributors who made this possible: - Marko Obrovac, Eric Evans, James Douglas and Hardik Juneja on the Services team worked hard to build RESTBase, and to make it as extensible and clean as it is now. - Filippo Giunchedi, Alex Kosiaris, Andrew Otto, Faidon Liambotis, Rob Halsell and Mark Bergsma helped to procure and set up the Cassandra storage cluster backing this API. - The Parsoid team with Subbu Sastry, Arlo Breault, C. Scott Ananian and Marc Ordinas i Llopis is solving the extremely difficult task of converting between wikitext and HTML, and built a new API that lets us retrieve and pass in metadata separately. - On the MediaWiki core team, Brad Jorsch quickly created a minimal authorization API that will let us support private wikis, and Aaron Schulz, Alex Monk and Ori Livneh built and extended the VirtualRestService that lets VisualEditor and MediaWiki in general easily access external services. We welcome your feedback here: https://www.mediawiki.org/wiki/Talk:RESTBase - and in Phabricator https://phabricator.wikimedia.org/maniphest/task/create/?projects=RESTBasetitle=Feedback: . Sincerely -- Gabriel Wicke Principal Software Engineer, Wikimedia Foundation ___ Engineering mailing list engineer...@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/engineering ___ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Re: [Wikitech-l] [BREAKING CHANGE] Plans to move Cite configuration from wikitext messages to CSS styles
On Tue, Dec 16, 2014 at 11:44 AM, Marc Ordinas i Llopis marc...@wikimedia.org wrote: TL;DR: * References made using Cite will be configurable with a different system * New approach being prototyped in Parsoid's native implementation of the Cite extension FYI: There's now a Phabricator task to track this work at https://phabricator.wikimedia.org/T86782. -- Marc ___ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Re: [Wikitech-l] [BREAKING CHANGE] Plans to move Cite configuration from wikitext messages to CSS styles
On Wed, Dec 17, 2014 at 2:50 PM, Derk-Jan Hartman d.j.hartman+wmf...@gmail.com wrote: Ehm, has accessibility been taken into account with this design ? Quoting WebAIM: Always use native HTML markup to provide the necessary semantic content and meaning, then use CSS to enhance and change the default styles. Yes, the current patch provides a default-style rendering using only HTML, then on browsers that support it, hides that default rendering and substitutes it with a modern, CSS counters-based styling. Marc ___ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
[Wikitech-l] [BREAKING CHANGE] Plans to move Cite configuration from wikitext messages to CSS styles
All, TL;DR: * References made using Cite will be configurable with a different system * New approach being prototyped in Parsoid's native implementation of the Cite extension The Cite extension[0], which provides in-page footnotes is a crucial part of how many of us use wikis, especially for Wikipedias. However, it was written a very long time ago, even by MediaWiki standards, and in its creation, we made some design choices which made sense at the time, but don't work very well for us anymore. As CSS has gotten more features, and those features have become more reliably implemented in modern browsers, we have more choices now. One of the great things about the Cite extension is its flexibility, such as each wiki being able to choose how the footnotes display to readers. Unfortunately, the means by which this flexibility is provided is currently done through a series of 14 different MediaWiki namespace wikitext messages which are interpreted to create the HTML to display to the user. This has a number of disadvantages. Most wikis use the default values (and even very experienced users are probably unaware of how it works or even that it can be changed). Because they are implemented in wikitext, per-user changes such as with a gadget or a user script aren't possible to do neatly (and instead need JavaScript to re-write the content, which is slower and more complex), and changes take up to 30 days to be visible to anonymous users whilst they wait for the cache to change. Due to how MediaWiki's messages system works, changes to the display styles need to be copied into each of the ~300 display languages for users, else those users with different languages will see different reference styles on the same page. Any system that wishes to display MediaWiki references has to implement most of MediaWiki just to format these references correctly. To fix this, the Parsoid and editing teams are proposing to replace the current way to configure the Cite extension with some CSS rules, which will solve these issues. Experimenting will be much easier to do on a per-user or gadget-basis in advance of making larger changes. Styles will be shared by all users of the wiki, regardless of their preferred language, and complicated user scripts or gadgets that slow down the system will not be needed to change the style. Changes will be instant for all users, even those logged out, and non-MediaWIki users can use styles to correctly and consistently display references. A currently-under-review patch[1] for Parsoid demonstrates use of CSS to do variations found on enwiki, eswiki, and fawiki. We think that this approach will allow us to match each of the current styles used on Wikimedia wikis. If there is any variation (currently in use) that we should experiment with, please let us know. We plan to continue to prototype this approach in Parsoid and work through any rendering issues. Given that most Wikimedia wikis don't customize the extension, for most Wikimedia wikis, we expect this will work with the basic configuration (and for a few Wikipedias which need different configuration, we will add styling). Once we port this solution over to the master branch of the Cite extension, this will be a breaking configuration change in the MediaWiki 1.25 release. If you have a gadget or user script which changes how references appear or relies on something local to your wikis, you may need to tweak it. Given that older browsers (IE6 and IE7 most notably) may not implement the CSS features that we need for this, we don't plan to rely solely on a CSS-based approach. Our current approach is to use a default bare HTML style on browsers that don't support content generation (like ::after and counters). We invite your comments, feedback, and help with this. Thanks, Marc, Parsoid and Editing teams. [0] – https://www.mediawiki.org/wiki/Extension:Cite [1] – https://gerrit.wikimedia.org/r/#/c/170936/ ___ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Re: [Wikitech-l] Dynamic unit conversion
On Fri, Jan 17, 2014 at 9:58 AM, Petr Bena benap...@gmail.com wrote: For example you would say the object has width of {{unit|cm=20}} and people who prefer cm would see 20 cm in article text, but people who prefer inches would see 7.87 inch. This is a great idea! As proposed it'd be very helpful, but maybe it'd be better if it showed the original text and a conversion on mouse-over (maybe with a small icon to indicate it, like external links). This could be even based on geolocation for IP users Oh, please, don't use IP geolocation for anything. It's terrible for people travelling, using proxies, living abroad, living in places where more than one languages are commonly spoken, learning new languages… If you want to get an initial default, use Accept-Language (like, inches for en-US and cm for anyone else :) and allow the user to modify it. Thanks, Marc ___ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Re: [Wikitech-l] dirty diffs and VE
On Wed, Jul 24, 2013 at 1:55 AM, John Vandenberg jay...@gmail.com wrote: Could you provide a dump of the list of 24000 bustable pages? Split by project? Each community could then investigate those pages for broken tables, and more critically .. templates which emit broken wikisyntax that is causing your team grief. As Subbu said, I'm currently working on improving the round-trip test server, mostly on porting it from sqlite to MySQL but also on expanding the stats kept (with things like performance, etc.). If you think of some other data we should track, or any new report we could add, we certainly welcome suggestions :) Please open a new bug or add to the existing one: https://bugzilla.wikimedia.org/show_bug.cgi?id=46659 Or just drop by #wikimedia-parsoid, I'm marcoil there. Cheers, Marc ___ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Re: [Wikitech-l] dirty diffs and VE
On Wed, Jul 24, 2013 at 4:58 PM, Roan Kattouw roan.katt...@gmail.comwrote: Or just drop by #wikimedia-parsoid, I'm marcoil there. The channel is #mediawiki-parsoid :) Yes, sorry… I hadn't had enough coffee :) ___ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l