#include <bits/stdc++.h>
using namespace std;
long long mod = 1e9 + 7;
void fast() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
}
bool primecheck(long long n) {
  for (long long i = 2; i <= sqrt(n); i++) {
    if (n % i == 0) {
      return 0;
    }
  }
  return 1;
}
long long power(long long x, long long y, long long mod) {
  long long res = 1;
  while (y > 0) {
    if (y & 1) res = (res * x) % (mod);
    y = y >> 1;
    x = (x * x) % mod;
  }
  return res % mod;
}
int main() {
  fast();
  string str;
  cin >> str;
  long long sum = 0;
  for (long long i = 0; i < str.length(); i++) {
    if (str[i] == '0') {
      sum++;
    } else {
      sum--;
    }
    if (sum < 0) {
      cout << -1;
      return 0;
    }
  }
  sum = 0;
  for (long long i = str.length() - 1; i >= 0; i--) {
    if (str[i] == '0') {
      sum++;
    } else {
      sum--;
    }
    if (sum < 0) {
      cout << -1;
      return 0;
    }
  }
  if (sum <= 0) {
    cout << -1;
    return 0;
  }
  vector<long long> v[200002];
  long long c = 0;
  set<long long> s;
  for (long long i = 0; i < str.length(); i++) {
    if (str[i] == '0') {
      v[c + 1].push_back(i + 1);
      s.insert(c + 1);
      c++;
    } else {
      v[c].push_back(i + 1);
      s.insert(c);
      c--;
    }
  }
  long long i = 1;
  cout << s.size() << "\n";
  while (v[i].size()) {
    cout << v[i].size() << ' ';
    for (auto x : v[i]) {
      cout << x << ' ';
    }
    cout << "\n";
    i++;
  }
}
