But, this isn't just philanthropy. As SFGate points out, it's an obligation:

In a deal to keep the company from leaving San Francisco, the city allowed certain Mid-Market companies to avoid payroll taxes for six years by signing a community benefits agreement promising contributions to nearby areas, some of the poorest parts of the Bay Area.

The Compass partnership will not count toward Twitter's obligations for this year's agreement, but company officials say it could count in future years.

Twitter employees will volunteer to teach educational workshops for both parents and children. A location for the learning center hasn't been nailed down yet, but it will be somewhere near Twitter's headquarters in the city. It will include a classroom for about 30 students, and will open sometime in June 2015.

The center won't teach coding skills. It will focus on teaching basic technology skills, such as accessing government services and how to apply for jobs online.